From 6cffa10d2b570620bb74517edf0f93211ec7d236 Mon Sep 17 00:00:00 2001 From: doylet Date: Thu, 18 Apr 2024 21:08:44 +1000 Subject: [PATCH] Adjust some windows scripts --- Win/Scripts/devenver_env.bat | 23 +++++++++++++++++++++++ Win/Scripts/msys2_env.bat | 2 +- Win/Scripts/node_env.bat | 20 ++++++++++---------- app_manifest_dev.py | 4 ++-- 4 files changed, 36 insertions(+), 13 deletions(-) create mode 100644 Win/Scripts/devenver_env.bat diff --git a/Win/Scripts/devenver_env.bat b/Win/Scripts/devenver_env.bat new file mode 100644 index 0000000..ad0b2da --- /dev/null +++ b/Win/Scripts/devenver_env.bat @@ -0,0 +1,23 @@ +@echo off +setlocal EnableDelayedExpansion +set root_path=%devenver_root%\NodeJS +set version=%~1 +for /f "tokens=1,* delims= " %%a in ("%*") do set remaining_args=%%b + +if "%~1"=="help" goto :help +if "%~1"=="" goto :help +if "%~1"=="--help" goto :help +if "%~1"=="/?" goto :help +goto :run + +:help +echo USAGE: node_env.bat ^ [^] +echo. +echo VERSIONS: +ls %root_path% +goto :eof + +:run +echo [SCRIPT] Adding to path '%root_path%\%version%' and executing '%remaining_args%' +set PATH=%root_path%\%version%;%PATH% +%remaining_args% diff --git a/Win/Scripts/msys2_env.bat b/Win/Scripts/msys2_env.bat index 2bb3a61..e628a8b 100644 --- a/Win/Scripts/msys2_env.bat +++ b/Win/Scripts/msys2_env.bat @@ -24,5 +24,5 @@ goto :eof set msys_env=%~1 for /f "tokens=1,* delims= " %%a in ("%*") do set remaining_args=%%b -echo [SCRIPT] Executing '%devenver_root%\MSYS2\20240113\msys2_shell.cmd -%msys_env% -no-start -defterm -here -c "%remaining_args%"' +echo [SCRIPT] Executing '%devenver_root%\MSYS2\20240113\msys2_shell.cmd -%msys_env% -no-start -defterm -here -c "%remaining_args%" %devenver_root%\MSYS2\20240113\msys2_shell.cmd -%msys_env% -no-start -defterm -here -c "%remaining_args%" diff --git a/Win/Scripts/node_env.bat b/Win/Scripts/node_env.bat index aa9ef6b..ad0b2da 100644 --- a/Win/Scripts/node_env.bat +++ b/Win/Scripts/node_env.bat @@ -1,23 +1,23 @@ @echo off setlocal EnableDelayedExpansion set root_path=%devenver_root%\NodeJS +set version=%~1 +for /f "tokens=1,* delims= " %%a in ("%*") do set remaining_args=%%b -if "%~1"=="help" goto :help -if "%~1"=="" goto :help -if "%~1"=="--help" goto :help -if "%~1"=="/?" goto :help +if "%~1"=="help" goto :help +if "%~1"=="" goto :help +if "%~1"=="--help" goto :help +if "%~1"=="/?" goto :help goto :run :help -echo USAGE: node_env.bat ^ ^ +echo USAGE: node_env.bat ^ [^] echo. echo VERSIONS: ls %root_path% goto :eof :run -set version=%~1 -for /f "tokens=1,* delims= " %%a in ("%*") do set remaining_args=%%b -echo [SCRIPT] Executing %root_path%\%version%\%remaining_args% - -%root_path%\%version%\%remaining_args% +echo [SCRIPT] Adding to path '%root_path%\%version%' and executing '%remaining_args%' +set PATH=%root_path%\%version%;%PATH% +%remaining_args% diff --git a/app_manifest_dev.py b/app_manifest_dev.py index 2bbbf41..cf8ab99 100644 --- a/app_manifest_dev.py +++ b/app_manifest_dev.py @@ -914,7 +914,7 @@ def get_manifest(is_windows): { "path": exe_path, "symlink": symlink, - "add_to_devenv_path": True, + "add_to_devenv_path": False, "checksum": checksum, } ], @@ -945,7 +945,7 @@ def get_manifest(is_windows): { "path": exe_path, "symlink": symlink, - "add_to_devenv_path": True, + "add_to_devenv_path": False, "checksum": checksum, } ],