rbenv: rbenv shell command not found
Environment:
$ uname -srvm
Linux 3.11.0-11-generic #17-Ubuntu SMP Tue Oct 1 19:42:04 UTC 2013 x86_64
$ echo $SHELL
/usr/bin/fish
$ rbenv --version
rbenv 0.4.0-65-gff23666
When I execute rbenv shell jruby-1.7.4
rbenv outputs rbenv: no such command `shell’
and the ruby environment doesn’t change.
In order to mitigate this issue I’m using this:
function rbenv-shell
set --local RUBY_VERSION $argv[1]
if test "$RUBY_VERSION" = "--unset"
set --global --export --erase RBENV_VERSION
else if test -n "$RUBY_VERSION"
set --global --export RBENV_VERSION $RUBY_VERSION
end
rbenv version
end
complete --command rbenv-shell --exclusive --arguments "--unset (rbenv versions --bare)"
About this issue
- Original URL
- State: closed
- Created 11 years ago
- Comments: 20 (7 by maintainers)
Commits related to this issue
- Update instructions for $PATH change in README Describe for Fish shell in details, prevent issues like #195 and #459. Reference: https://fishshell.com/docs/2.7/tutorial.html#tut_path — committed to AlexWayfer/rbenv by AlexWayfer 6 years ago
- Update instructions for $PATH change in README Describe for Fish shell in details, prevent issues like #195 and #459. Reference: https://fishshell.com/docs/2.7/tutorial.html#tut_path — committed to jrolfs/rbenv by AlexWayfer 6 years ago
How did you set up rbenv? Did you follow instructions from the official README? Do you have this line in your
.bash_profile
or.zshrc
(depending on the shell you use):rbenv shell
is a special command that only works if you’ve set up therbenv()
function in your shell by means of eval’ingrbenv init -
output.