From 4a6c696074d89b63ce60c0c68e16712870427785 Mon Sep 17 00:00:00 2001 From: Koen Punt Date: Tue, 9 Oct 2012 13:36:44 +0200 Subject: [PATCH] Made string comparison also compatible for zsh --- nvm.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/nvm.sh b/nvm.sh index 1804925..2bed1f5 100755 --- a/nvm.sh +++ b/nvm.sh @@ -75,7 +75,7 @@ nvm_ls_remote() { PATTERN=$1 if [ "$PATTERN" ]; then - if [ "${PATTERN:0:1}" != "v" ]; then + if echo "${PATTERN}" | grep -v '^v' ; then PATTERN=v$PATTERN fi fi