Last active
August 22, 2023 12:20
-
-
Save bjesuiter/5c7b882fa71f0b15186aa5714cd0f419 to your computer and use it in GitHub Desktop.
Windows CMD Tricks
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# 'Res-Params' - Get a list of all params after a finite amout of params | |
# For Example: Collect all params after %1 to pass them to another cli. | |
set param_1=%1 | |
for /f "tokens=1,* delims= " %%a in ("%*") do set ALL_BUT_FIRST_PARAM=%%b | |
echo "Call Some other cli with the rest of the params: %ALL_BUT_FIRST_PARAM%" | |
# For Example: call %CMDER_ROOT%\opt\.wapm\wapm_packages\.bin\%command% %ALL_BUT_FIRST% | |
# reload windows environment variables (win env) without reboot | |
# https://search4fan.github.io/post/win10_new_system_variable_without_restart.html | |
set PATH=C |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment