Permalink
Browse files

support passing a ruby name to `ry setup`

  • Loading branch information...
1 parent de85b7c commit d612dee3035f5efe4b6c9f8a19472a5671dfa074 @jneen committed Mar 18, 2012
Showing with 6 additions and 1 deletion.
  1. +6 −1 bin/ry
View
7 bin/ry
@@ -74,9 +74,14 @@ ry::current() {
basename "$(readlink "$RY_LIB/current")"
}
+#
+# eval "$(ry setup [<name>])"
+# a shortcut to load the correct paths and
+# activate the completion
+#
ry::setup() {
cat <<sh
-export PATH="$RY_LIB/current/bin:\$PATH";
+export PATH="$(ry fullpath "$@")"
. "$RY_PREFIX/lib/ry.bash_completion"
sh
}

0 comments on commit d612dee

Please sign in to comment.