In Windows 10, some environment variables actually use percentage signs to refer to paths. For example, the PSModulePath environment variable looks like this (ignore the additional one I marked out):
and you'll notice that it uses percentage signs to refer to certain directories instead of hard-coded paths. Suppose that I have several environment variables that I want to add, but I would like them to refer to custom directories of my own. For example, if I wanted to add some folder named "Include" located in some custom directory to an environment variable, ideally all I would have to do is add this text to the corresponding environment variable:
%MyCustomDirectoryVariable%\Include
But, of course, there's a problem; I'm not sure if it's even possible to create my own percentage sign variables that can refer to specific directories! Is it possible for me to create my own custom percentage sign variable that the environment variables can properly interpret as a directory? Or if I want to add my own path to an environment variable, must it always be a hard-coded path?
No comments:
Post a Comment