Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
npm-bin: Prefer locally installed npm in Git Bash.
Existing behavior invoking npm within a Git Bash session is to prefer the globally installed instance of `npm`; the instance of npm installed alongside Node when using the Node installer. The cmd script, and the shell script, have been modified in the past to pull a `prefix` setting from the global `npmrc` file, and invoke the `npm` instance located at the `prefix` location. Because the value of `prefix` is the user's AppData directory where npm installs new copies of itself, the user gets the latest installed npm. However, the setup was not extended to support Git Bash. Therefore Git Bash users still get the version of npm installed beside Node. Add support for using the same prefix for invoking the user installed npm in Git Bash sessions. PR-URL: npm/npm#11526 Credit: @destroyerofbuilds Reviewed-By: @iarna Fixes: #11524
- Loading branch information