From 666e1794fab303a9e7594244aeab0736eb82e5b2 Mon Sep 17 00:00:00 2001 From: Marc Harter Date: Thu, 20 Jan 2011 16:47:30 -0600 Subject: [PATCH] another solution to get ZSH and BASH both to work --- nvm.sh | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/nvm.sh b/nvm.sh index fafc0bc..9e9951b 100644 --- a/nvm.sh +++ b/nvm.sh @@ -5,8 +5,7 @@ # Implemented by Tim Caswell # with much bash help from Matthew Ranney -eval last=\${$#} -export NVM_DIR=$(dirname $last) +export NVM_DIR=$(cd $(dirname ${BASH_SOURCE[0]:-$0}); pwd) nvm() {