So replace WHAT with PATH and your script will see $PATH just fine. I used WHAT because the name of the variable does not matter since you are not using a shell in LIST mode, and PATH has no more special meaning than WHAT does.
Beyond that, the only problem I see in your posted code is that you don't give a full path to /bin/bash (and $path isn't defined, but maybe you did that elsewhere).
In reply to Re^7: System() in list mode?
by onelesd
in thread System() in list mode?
by 1337John
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |