Is there any command line tool that can be used to edit environment variables in Windows?
It would be nice if this was smart tool, for example:
- When adding some path to let's say the PATH variable and this path is already there it shouldn't double this entry.
- Inserting a new path to the PATH variable should be possible before/after some other path or in specific order (the first, the 7th, the last etc.).
- It should be possible to change only part of variable's value (in case of the PATH a given path from a list of all paths).
And the last but not the least - I want my changes to persist between sessions so simple SET is out of question...
There's very nice GUI tool for this called Path Editor and I need something like this but for command line.
Answer
Path Manager (pathman.exe) from Windows Server 2003 Resource Kit Tools is the closest match I could find. It was already available in NT Resource Kit.
No comments:
Post a Comment