Use [0-9] instead of [[:digit:]] per https://github.com/creationix/nvm/pull/466#discussion_r14853668 - it's simpler (and probably more portable).
diff --git a/nvm.sh b/nvm.sh
index 78a37cf..4509dc7 100644
--- a/nvm.sh
+++ b/nvm.sh
@@ -153,13 +153,13 @@
     return
   fi
   # If it looks like an explicit version, don't do anything funny
-  if [ `expr "$PATTERN" : "v[[:digit:]]*\.[[:digit:]]*\.[[:digit:]]*$"` != 0 ]; then
+  if [ `expr "$PATTERN" : "v[0-9]*\.[0-9]*\.[0-9]*$"` != 0 ]; then
     if [ -d "$NVM_DIR/$PATTERN" ]; then
       VERSIONS="$PATTERN"
     fi
   else
     PATTERN=$(nvm_format_version $PATTERN)
-    if [ `expr "$PATTERN" : "v[[:digit:]]*\.[[:digit:]]*$"` != 0 ]; then
+    if [ `expr "$PATTERN" : "v[0-9]*\.[0-9]*$"` != 0 ]; then
       PATTERN="$PATTERN."
     fi
     VERSIONS=`find "$NVM_DIR/" -maxdepth 1 -type d -name "$PATTERN*" -exec basename '{}' ';' \