A command line tool to edit Edit environment variable.
If you have .Net SDK installed on your computer, you can install EditEnv by dotnet tool:
dotnet tool install EditEnv --globalor, download the EditEnv.exe , add it's directory to user Path environment variable.
Set user environment variable key value pair
EditEnv set test -v 123
EditEnv set test -v 123456
The Variable key [test] is exist, will you update it? (y/n) y
Set :test = 123456Get user environment variable by key
EditEnv get testRemove user environment variable by key
EditEnv remove testAdd directory to PATH
EditEnv path add -v D:\code\vsproject\EditEnv
EditEnv path add -v "C:\Program Files\ContextMenuTools\ImageProcess"
EditEnv set test -v 123 --target machine
The Variable key [test] is exist, will you update it? (y/n) y
Set :test = 123
EditEnv remove test --target machine
Remove directory from PATH
EditEnv path remove -v D:\code\vsproject\EditEnvList all directory in PATH
EditEnv path listTo modify system environment variables, you need to open the terminal with administrator privileges.
EditEnv set test -v 123 --target machine