在尝试将 Bundler 与 ruby 1.9.3p194 一起使用时,我收到了错误:
> gem install bundler
Fetching: bundler-1.5.1.gem (100%)
> bundle install
fish: Unknown command 'bundle'
Rbenv 的初始化config.fish
如下:
set -x PATH "$HOME/.rbenv/bin" $PATH
. (rbenv init - | psub)
和输出rbenv init -
:
> rbenv init -
setenv RBENV_SHELL fish
. '/Users/nifl/.rbenv/libexec/../completions/rbenv.fish'
rbenv rehash 2>/dev/null
function rbenv
set command $argv[1]
set -e argv[1]
switch "$command"
case rehash shell
eval (rbenv "sh-$command" $argv)
case '*'
command rbenv "$command" $argv
end
end
我没有将 fish 设置为默认 shell,并且 Bundler 在 Bash 中运行良好。