Jump to content

Recommended Posts

Posted

Does anyone know how to edit the command line PATH variable to include commands with just by calling the .exe from anywhere in the directory structure? This is of course in WinPE 2?


Posted (edited)

Here is a description of how they are added at runtime, I assume it should require you build you PE with the scripting environment if you have not already done so. These path variables will get reset each time the script is run. So be aware of that if you are writing multiple scripts that need these variables. They need to be specified in each script.

It starts about a third the way down. The PATH Environment Variable

http://vlaurie.com/computers2/Articles/environment.htm

If you read further in the thread it describes how to preset them via the registry. I assume this could be applied somehow into the HIVE's inside your PE.wim. Or integrated into your WIM via a registry setting .INF file. But it seems easiest just to set them at run-time.

EDIT: On second read, I suggest this "path = %PATH%;newdir " or "path = %PATH%;C:\MyPath" as that is non-destructive to existing path variables.

Edited by MrJinje

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...