Skip to content

Commit

Permalink
fix: fix regression on npm/yarn path when it has white space
Browse files Browse the repository at this point in the history
  • Loading branch information
3cp committed Sep 12, 2018
1 parent fdcac90 commit 3641a92
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion lib/package-managers/npm.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ exports.NPM = class {
}

installCommand(executablePath, packages) {
let cmd = `${executablePath} install`;
let cmd = `"${executablePath}" install`;
if (packages && packages.length > 0) {
cmd += ` ${packages.join(' ')}`;
}
Expand Down
2 changes: 1 addition & 1 deletion lib/package-managers/yarn.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ exports.Yarn = class extends npm {
}

installCommand(executablePath, packages) {
let cmd = `${executablePath}`;
let cmd = `"${executablePath}"`;
if (packages && packages.length > 0) {
cmd += ` add ${packages.join(' ')}`;
}
Expand Down

0 comments on commit 3641a92

Please sign in to comment.