New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
tasks.json npm script does not work with arguments since 1.53 #115876
Comments
I didn't realize users were adding args to npm tasks in |
@alexr00 Or, support |
@alexr00 You have probably forgotten your older comment with a npm script params #82626 (comment) 😉 |
Indeed, I had forgotten that, thank you. Since this used to work and now does not, I'd like to fix it. |
No. As a user you can either have the old behavior where we support arguments, or you can have the new behavior where script names have spaces. |
I am happy with the "old behavior where we support arguments". You should ask @jonamat if he is happy with breaking #113750 That's why I have proposed to add |
I have converted type {
"label": "test:web current file",
"type": "shell",
"command": "npm",
"argv": [ "run", "test:web", "--", "suites=\"${relativeFileDirname}/${fileBasenameNoExtension}\"" ]
} And it does the job well. IMHO either type |
The fix for this bug allows the following:
The fix for this bug does not allow you have a task that uses an npm script with a space and the |
OK, just such automagic behaviour may be very confusing when not documented. Please, document the https://code.visualstudio.com/docs/editor/tasks - For a custom task, this can either be It's difficult to find what's a proper behaviour and what is a bug without doc. |
Steps to Reproduce:
I have a npm task (
tasks.json
):It has been working fine until I have upgraded to 1.53. Since then, I got error:
Seems to me v1.53 has added shell escaping. So, how I can add arguments to a task npm?
Also, I am miss information about additional npm tasks properties in
Does this issue occur when all extensions are disabled?: Yes
The text was updated successfully, but these errors were encountered: