From 01610706878b1bdc0509b81d357acc9c64368fe2 Mon Sep 17 00:00:00 2001 From: Tj Holowaychuk Date: Wed, 5 Jan 2011 07:25:55 -0800 Subject: [PATCH] return when active --- bin/n | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/bin/n b/bin/n index a99bdbf..298687a 100755 --- a/bin/n +++ b/bin/n @@ -105,12 +105,16 @@ display_versions() { install_node() { local version=$1 + check_current_version # remove "v" if test "${version:0:1}" = "v"; then version=${version:1:${#version}} fi + # already active + test "$version" = "$installed" && return + # install local dir="node-v$version" cd $PREFIX/n \