Skip to content

Fix Case Sensitive NPM_EXECPATH #84

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

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion bin/npm-run-all/help.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ Options:
--max-parallel <number> - Set the maximum number of parallelism. Default is
unlimited.
--npm-path <string> - - - Set the path to npm. Default is the value of
environment variable NPM_EXECPATH.
environment variable npm_execpath.
If the variable is not defined, then it's "npm".
In this case, the "npm" command must be found in
environment variable PATH.
Expand Down
2 changes: 1 addition & 1 deletion bin/run-p/help.js
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ Options:
--max-parallel <number> - Set the maximum number of parallelism. Default is
unlimited.
--npm-path <string> - - - Set the path to npm. Default is the value of
environment variable NPM_EXECPATH.
environment variable npm_execpath.
If the variable is not defined, then it's "npm."
In this case, the "npm" command must be found in
environment variable PATH.
Expand Down
2 changes: 1 addition & 1 deletion bin/run-s/help.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ Options:
itself will exit with non-zero code if one or
more tasks threw error(s).
--npm-path <string> - - - Set the path to npm. Default is the value of
environment variable NPM_EXECPATH.
environment variable npm_execpath.
If the variable is not defined, then it's "npm."
In this case, the "npm" command must be found in
environment variable PATH.
Expand Down
2 changes: 1 addition & 1 deletion docs/node-api.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ Run npm-scripts.
Default is `Number.POSITIVE_INFINITY`.
- **options.npmPath** `string` --
The path to npm.
Default is `process.env.NPM_EXECPATH` or `"npm"`.
Default is `process.env.npm_execpath` or `"npm"`.
- **options.packageConfig** `object|null` --
The map-like object to overwrite package configs.
Keys are package names.
Expand Down
2 changes: 1 addition & 1 deletion docs/npm-run-all.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ Options:
--max-parallel <number> - Set the maximum number of parallelism. Default is
unlimited.
--npm-path <string> - - - Set the path to npm. Default is the value of
environment variable NPM_EXECPATH.
environment variable npm_execpath.
If the variable is not defined, then it's "npm."
In this case, the "npm" command must be found in
environment variable PATH.
Expand Down
2 changes: 1 addition & 1 deletion docs/run-p.md
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ Options:
--max-parallel <number> - Set the maximum number of parallelism. Default is
unlimited.
--npm-path <string> - - - Set the path to npm. Default is the value of
environment variable NPM_EXECPATH.
environment variable npm_execpath.
If the variable is not defined, then it's "npm."
In this case, the "npm" command must be found in
environment variable PATH.
Expand Down
2 changes: 1 addition & 1 deletion docs/run-s.md
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ Options:
itself will exit with non-zero code if one or
more tasks threw error(s).
--npm-path <string> - - - Set the path to npm. Default is the value of
environment variable NPM_EXECPATH.
environment variable npm_execpath.
If the variable is not defined, then it's "npm."
In this case, the "npm" command must be found in
environment variable PATH.
Expand Down
2 changes: 1 addition & 1 deletion lib/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@ function maxLength(length, name) {
* Default is unlimited.
* @param {string} options.npmPath -
* The path to npm.
* Default is `process.env.NPM_EXECPATH`.
* Default is `process.env.npm_execpath`.
* @returns {Promise}
* A promise object which becomes fullfilled when all npm-scripts are completed.
*/
Expand Down
2 changes: 1 addition & 1 deletion lib/run-task.js
Original file line number Diff line number Diff line change
Expand Up @@ -136,7 +136,7 @@ module.exports = function runTask(task, options) {
}

if (path.extname(options.npmPath || "a.js") === ".js") {
const npmPath = options.npmPath || process.env.NPM_EXECPATH //eslint-disable-line no-process-env
const npmPath = options.npmPath || process.env.npm_execpath //eslint-disable-line no-process-env
const execPath = npmPath ? process.execPath : "npm"
const spawnArgs = [].concat(
npmPath ? [npmPath, "run"] : ["run"],
Expand Down