|I like the check you are doing, with the FOR command, but really : this thread is about setting the PATH, and more specific, setting it inside AUTOEXEC |
You can do a check, but just there, in AUTOEXEC, it's not really necessary, since the PATH you are adding, is just the one that you want to add to the MS defaults.
Logically, that would not be the case, since you are adding a custom path. So, a check, inside AUTOEXEC, is not necessary.
But I agree 100%, that a check inside anything else but a boot related script, is very nice to have.
Then you may need the FOR command, and then you need to double up the percentages. Note that we then are speaking about the FOR command, which is not the same as the SET command ... but, that is not really what you don't know.
Anyway, both on Windows and Unix and Linux, it CAN be the case that you want to prepend a path, but you must know what you are doing.