I am trying to execute a small perl6 script via Notepad++ and NppExec. My system is Windows 10 and i set the PATH variable properly to C:\rakudo\bin where the perl6 executable is. When i am executing the script via normal console with:
perl6 "path/to/script.pl6"
it gets executed without a problem.
However, when i execute the exact same command in NppExec as following:
CD $(CURRENT_DIRECTORY)
perl6 "$(FILE_NAME)"
i get the error: CreateProcess() failed with error code 2: The system cannot find the file specified.
Obviously, the command "perl6" is unkown to NppExec... My question: How can i make the PATH variable known to NppExec or is this problem related to something else?
You can show the PATH that NppExec knows with the following NppExec command:
env_set PATH
So you can check if the path to perl is there or not. A rather simple way to run perl would be using the full path to perl6 in you original script. Btw, you can use $(FULL_CURRENT_PATH)
.