Set group policy user logon or computer startup script to run locally

This is example how to convert group policy script with sed support to run locally.

This example can be run from UNC path.

All directory content (files who are got an extension) will be copied to %temp%\listpath sub directory and run from there.

Additional libraries are required:

After the script ends the %temp%\listpath will be removed:
This whole point of the program echo %path% | sed "s/;/\n/g" | sed "$d" is to show user all environment %path% variables in nice list. This is one example how powerful is sed.

Only one *.cmd file can be in directory.

No comments: