Skip to content

Commit

Permalink
Create alias dir on demand
Browse files Browse the repository at this point in the history
  • Loading branch information
agnoster committed Jan 25, 2011
1 parent 590b283 commit 45b89ab
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion nvm.sh
Expand Up @@ -154,8 +154,9 @@ nvm()
echo "# use 'nvm sync' to update from nodejs.org"
;;
"alias" )
mkdir -p $NVM_DIR/alias
if [ $# -le 2 ]; then
(cd $NVM_DIR/alias; for ALIAS in `ls $2* 2>/dev/null`; do
(cd $NVM_DIR/alias && for ALIAS in `ls $2* 2>/dev/null`; do
DEST=`cat $ALIAS`
VERSION=`nvm_version $DEST`
if [ "$DEST" = "$VERSION" ]; then
Expand Down

0 comments on commit 45b89ab

Please sign in to comment.