vscode-npm-scripts icon indicating copy to clipboard operation
vscode-npm-scripts copied to clipboard

Issue when running scripts containing spaces

Open TheDSCPL opened this issue 5 years ago • 0 comments

Hey!

I've detected a bug when the script's name contains spaces.

In my case, I have 2 scripts: "compile" and "deploy". Then I have a third script "compile and deploy". When I run this one with your tool, it runs "npm run compile and deploy", which creates an error because it tries to run the scripts "compile", "and" and then "deploy", which was not the intended behaviour!

I believe there is an easy fix: quote the script's name. Instead of running "npm run compile and deploy", run "npm run 'compile and deploy'".

TheDSCPL avatar Jun 28 '19 13:06 TheDSCPL