Skip to content

Commit

Permalink
[Fix] add missing quotes for $NODE_VERSION in nvm-exec
Browse files Browse the repository at this point in the history
  • Loading branch information
PeterDaveHello authored and ljharb committed Nov 24, 2016
1 parent 7ed1e71 commit ac63638
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion nvm-exec
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,11 @@

DIR="$(command cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"

# shellcheck disable=SC1090
\. "$DIR/nvm.sh" --no-use

if [ -n "$NODE_VERSION" ]; then
nvm use $NODE_VERSION > /dev/null || exit 127
nvm use "$NODE_VERSION" > /dev/null || exit 127
elif ! nvm use >/dev/null 2>&1; then
echo "No NODE_VERSION provided; no .nvmrc file found" >&2
exit 127
Expand Down

0 comments on commit ac63638

Please sign in to comment.