Skip to content
Merged
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
[Fix] Regression in 2dad045
Fixes #2599
  • Loading branch information
svenssonaxel authored and ljharb committed Sep 23, 2021
commit 11d71ab24b3b138dfc5b64f4183245ed89b81a64
2 changes: 1 addition & 1 deletion nvm.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2458,7 +2458,7 @@ nvm_die_on_prefix() {
# until none are left.
local NVM_NPM_CONFIG_x_PREFIX_ENV
if [ -n "${BASH_SOURCE-}" ]; then
NVM_NPM_CONFIG_x_PREFIX_ENV="$(command set | command awk -F '=' '! /^[0-9A-Z_a-z]+=/ {exit} {print $1}' | nvm_grep -i NPM_CONFIG_PREFIX | command tail -1)"
NVM_NPM_CONFIG_x_PREFIX_ENV="$(command set | command awk -F '=' '! /^[0-9A-Z_a-z]+=/ {skip=1} skip==0 {print $1}' | nvm_grep -i NPM_CONFIG_PREFIX | command tail -1)"
else
NVM_NPM_CONFIG_x_PREFIX_ENV="$(command env | nvm_grep -i NPM_CONFIG_PREFIX | command tail -1 | command awk -F '=' '{print $1}')"
fi
Expand Down