Skip to content

Commit

Permalink
only escape arguments, not the command name
Browse files Browse the repository at this point in the history
PR-URL: #1906
Credit: @nlf
Close: #1906
Reviewed-by: @ruyadorno
  • Loading branch information
nlf authored and ruyadorno committed Oct 9, 2020
1 parent 518fa12 commit 9320b8e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/exec.js
Expand Up @@ -90,7 +90,7 @@ const exec = async args => {

if (binExists) {
return await runScript({
cmd: args.map(escapeArg).join(' ').trim(),
cmd: [args[0], ...args.slice(1).map(escapeArg)].join(' ').trim(),
banner: false,
// we always run in cwd, not --prefix
path: process.cwd(),
Expand Down

0 comments on commit 9320b8e

Please sign in to comment.