This website works better with JavaScript.
Home
Explore
Help
Sign In
isprogram
/
pyenv
mirror of
https://github.com/pyenv/pyenv.git
Watch
1
Star
0
Fork
0
Code
Issues
0
Projects
0
Releases
240
Wiki
Activity
Browse Source
Only shift if an argument is passed.
Fixes
#78
.
pull/360/head^2
Sam Stephenson
15 years ago
parent
1ba2ce0cb6
commit
fb6eee26d4
1 changed files
with
8 additions
and
5 deletions
Split View
Diff Options
Show Stats
Download Patch File
Download Diff File
+8
-5
libexec/rbenv-init
+ 8
- 5
libexec/rbenv-init
View File
@ -70,14 +70,17 @@ echo 'rbenv rehash 2>/dev/null'
commands=(`rbenv commands --sh`)
IFS="|"
cat <<EOS
function rbenv () {
command="\$1";
shift;
function rbenv() {
command="\$1"
if [ "\$#" -gt 0 ]; then
shift
fi
case "\$command" in
${commands[*]})
eval \`rbenv "sh-\$command" "\$@"\`;;
*)
command rbenv "\$command" "\$@";;
esac
;
}
;
esac
}
EOS
Write
Preview
Loading…
Cancel
Save