Comparing version 2.0.11 to 2.0.12-alpha.1
@@ -15,6 +15,23 @@ const utils = require('./utils'); | ||
var shFlag = '-c'; | ||
var spawnOptions = { | ||
env: merge(config.options.execOptions.env, env), | ||
stdio: stdio, | ||
}; | ||
if (utils.isWindows) { | ||
sh = 'cmd'; | ||
shFlag = '/c'; | ||
// if the exec includes a forward slash, reverse it for windows compat | ||
// but *only* apply to the first command, and none of the arguments. | ||
// ref #1251 and #1236 | ||
if (executable.indexOf('/') !== -1) { | ||
executable = executable.split(' ').map((e, i) => { | ||
if (i === 0) { | ||
return path.normalize(e); | ||
} | ||
return e; | ||
}).join(' '); | ||
} | ||
// taken from npm's cli: https://git.io/vNFD4 | ||
sh = process.env.comspec || 'cmd'; | ||
shFlag = '/d /s /c'; | ||
spawnOptions.windowsVerbatimArguments = true; | ||
} | ||
@@ -30,6 +47,3 @@ | ||
const env = merge(process.env, { FILENAME: eventArgs[0] }); | ||
const child = spawn(sh, [shFlag, args], { | ||
env: merge(config.options.execOptions.env, env), | ||
stdio: stdio, | ||
}); | ||
const child = spawn(sh, [shFlag, args], spawnOptions); | ||
@@ -36,0 +50,0 @@ if (config.required) { |
@@ -69,3 +69,4 @@ { | ||
}, | ||
"version": "2.0.11", | ||
"_version": "0.0.0-development", | ||
"version": "2.0.12-alpha.1", | ||
"funding": { | ||
@@ -72,0 +73,0 @@ "type": "opencollective", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
195057
45
2643
1
24