From ac29daaf3b35fe21fb9121312b1f37851d650ce8 Mon Sep 17 00:00:00 2001 From: deepak1556 Date: Tue, 9 Nov 2021 19:09:26 +0100 Subject: Fixes #136771: update to Electron v13.5.2 and pass `--ms-enable-run-as-node` together with `ELECTRON_RUN_AS_NODE` --- scripts/code-cli.bat | 2 +- scripts/code-cli.sh | 2 +- scripts/code.sh | 2 +- scripts/node-electron.bat | 4 ++-- scripts/node-electron.sh | 2 ++ 5 files changed, 7 insertions(+), 5 deletions(-) (limited to 'scripts') diff --git a/scripts/code-cli.bat b/scripts/code-cli.bat index c2eae24d4d9..a4a2c68ae02 100644 --- a/scripts/code-cli.bat +++ b/scripts/code-cli.bat @@ -24,7 +24,7 @@ set ELECTRON_ENABLE_LOGGING=1 set ELECTRON_ENABLE_STACK_DUMPING=1 :: Launch Code -%CODE% --inspect=5874 out\cli.js %~dp0.. %* +%CODE% --ms-enable-electron-run-as-node --inspect=5874 out\cli.js %~dp0.. %* goto end :builtin diff --git a/scripts/code-cli.sh b/scripts/code-cli.sh index a792c08532e..7d70a40aeff 100755 --- a/scripts/code-cli.sh +++ b/scripts/code-cli.sh @@ -34,7 +34,7 @@ function code() { VSCODE_DEV=1 \ ELECTRON_ENABLE_LOGGING=1 \ ELECTRON_ENABLE_STACK_DUMPING=1 \ - "$CODE" --inspect=5874 "$ROOT/out/cli.js" . "$@" + "$CODE" --ms-enable-electron-run-as-node --inspect=5874 "$ROOT/out/cli.js" . "$@" } code "$@" diff --git a/scripts/code.sh b/scripts/code.sh index 9caa49b1bf7..528e76f9c54 100755 --- a/scripts/code.sh +++ b/scripts/code.sh @@ -58,7 +58,7 @@ function code-wsl() cd $ROOT export WSLENV=ELECTRON_RUN_AS_NODE/w:VSCODE_DEV/w:$WSLENV local WSL_EXT_ID="ms-vscode-remote.remote-wsl" - local WSL_EXT_WLOC=$(echo "" | VSCODE_DEV=1 ELECTRON_RUN_AS_NODE=1 "$ROOT/.build/electron/Code - OSS.exe" "out/cli.js" --locate-extension $WSL_EXT_ID) + local WSL_EXT_WLOC=$(echo "" | VSCODE_DEV=1 ELECTRON_RUN_AS_NODE=1 "$ROOT/.build/electron/Code - OSS.exe" --ms-enable-electron-run-as-node "out/cli.js" --locate-extension $WSL_EXT_ID) cd $CWD if [ -n "$WSL_EXT_WLOC" ]; then # replace \r\n with \n in WSL_EXT_WLOC diff --git a/scripts/node-electron.bat b/scripts/node-electron.bat index 4ddb95b3cae..0d91ca9bc02 100644 --- a/scripts/node-electron.bat +++ b/scripts/node-electron.bat @@ -10,9 +10,9 @@ set NAMESHORT=%NAMESHORT: "=% set NAMESHORT=%NAMESHORT:"=%.exe set CODE=".build\electron\%NAMESHORT%" -%CODE% %* +%CODE% --ms-enable-electron-run-as-node %* popd endlocal -exit /b %errorlevel% \ No newline at end of file +exit /b %errorlevel% diff --git a/scripts/node-electron.sh b/scripts/node-electron.sh index 0a822b6c383..2e4dc6dbfe1 100755 --- a/scripts/node-electron.sh +++ b/scripts/node-electron.sh @@ -26,9 +26,11 @@ export VSCODE_DEV=1 if [[ "$OSTYPE" == "darwin"* ]]; then ulimit -n 4096 ; ELECTRON_RUN_AS_NODE=1 \ "$CODE" \ + --ms-enable-electron-run-as-node \ "$@" else ELECTRON_RUN_AS_NODE=1 \ "$CODE" \ + --ms-enable-electron-run-as-node \ "$@" fi -- cgit v1.2.3