在尝试将 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 中运行良好。
最佳答案
德普。之后需要重新哈希 > gem install bundler
> rbenv rehash
关于使用带有 rbenv 的 fish shell 找不到 bundle 程序,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/20985512/