emeraldwalk / vscode-runonsave

Visual Studio Code extension to run commands whenever a file is saved.
Apache License 2.0
182 stars 57 forks source link

spawn C:\WINDOWS\system32\cmd.exe ENOENT #28

Closed Jelmer7 closed 5 years ago

Jelmer7 commented 5 years ago

Whenever we make the extension run we get error: spawn C:\WINDOWS\system32\cmd.exe ENOENT

This is the correct path to cmd.exe. Vscode's terminal window still works, executing cmd.exe from this extension seems to be the problem.

Reverting back to 0.0.18 is a temporary fix

Extension version: 0.1.0 Version: 1.36.1 (user setup) Commit: 2213894ea0415ee8c85c5eea0d0ff81ecc191529 Date: 2019-07-08T22:59:35.033Z Electron: 4.2.5 Chrome: 69.0.3497.128 Node.js: 10.11.0 V8: 6.9.427.31-electron.0 OS: Windows_NT x64 10.0.18362

bmingles commented 5 years ago

Can you provide an example command that is causing this error?

Jelmer7 commented 5 years ago

Any command gives this error.

{
                "match": ".*",
                "cmd": "echo test",
},

29 is a duplicate of this

bmingles commented 5 years ago

Published a fix in 0.2.0

dae1b6624e8de698e94263d36a1b1bb905ca5e03

bmingles commented 5 years ago

@Jelmer7 Can you see if this fixes for you?

Jelmer7 commented 5 years ago

This indeed fixed it, thanks 👍