Open cawoodm opened 1 year ago
Just to add - I am running this from Powershell v7 on Windows 10.
If I run it from the command prompt cmd.exe it works fine.
Correction - it works under cmd.exe UNLESS we pass arguments to supervisor
$supervisor -- .\tests\script.js arg1
Running node-supervisor with
program '.\tests\script.js arg1'
--watch '.'
--extensions 'node,js'
--exec 'node'
Starting child process with 'node .\tests\script.js arg1'
Watching directory 'C:\projects\order' for changes.
Press rs for restarting the process.
$supervisor -w tests -n -- .\tests\script.js arg1
Running node-supervisor with
program 'arg1'
--watch 'tests'
--extensions 'node,js'
--exec 'node'
Starting child process with 'node arg1'
Watching directory 'C:\projects\order\tests' for changes.
Press rs for restarting the process.
node:internal/modules/cjs/loader:998
throw err;
^
Error: Cannot find module 'C:\projects\order\arg1'
Weirdly, adding -V
(or even -v
) causes it to work - though it would appear -v
(or whatever) is ignored:
C:\projects\order>supervisor -w tests -n -V -- .\tests\script.js arg1
If I run
supervisor script.js arg1
I expect it to runnode script.js arg1
however it seems to be runningnode arg1
.Version: latest: 0.12.0
Possibly related to #191