在Digital Ocean Droplet上设置rbenv并安装bundler,我无法通过rbenv将填充程序添加到填充程序中或能够运行rbenv exec bundle install
版本:
Ubuntu 14.04
rbenv 0.4.0-98-g13a474c
deploy$ gem -v
2.2.2
deploy$ ruby -v
ruby 2.1.2p95 (2014-05-08 revision 45877) [x86_64-linux]
deploy$ rbenv version
2.1.2 (set by /home/deploy/.rbenv/version)
我这样做了:
deploy@myip:~$ sudo gem install bundler
Fetching: bundler-1.6.3.gem (100%)
Successfully installed bundler-1.6.3
1 gem installed
deploy@myip:~$ which bundler
/usr/local/bin/bundler
deploy@myip:~$ rbenv rehash
deploy@myip:~$ ls .rbenv/shims
erb gem irb rake rdoc ri ruby testrb
我希望在rbenv rehash
之后在垫片中看到捆绑包。我还希望rbenv exec bundle install --binstubs
能够立即运行而不会出现错误。现在它给了我一个无命令错误:
deploy@myip:~/.rbenv/shims$ rbenv exec bundle install --binstubs
rbenv: bundle: command not found
我怀疑这个问题与我的RubyGems配置有关,但是看不出它有什么问题。看起来它在rbenv中执行安装和可执行文件。
RubyGems环境:
- RUBYGEMS VERSION: 2.2.2
- RUBY VERSION: 2.1.2 (2014-05-08 patchlevel 95) [x86_64-linux]
- INSTALLATION DIRECTORY: /home/deploy/.rbenv/versions/2.1.2/lib/ruby/gems/2.1.0
- RUBY EXECUTABLE: /home/deploy/.rbenv/versions/2.1.2/bin/ruby
- EXECUTABLE DIRECTORY: /home/deploy/.rbenv/versions/2.1.2/bin
- SPEC CACHE DIRECTORY: /home/deploy/.gem/specs
- RUBYGEMS PLATFORMS:
- ruby
- x86_64-linux
- GEM PATHS:
- /home/deploy/.rbenv/versions/2.1.2/lib/ruby/gems/2.1.0
- /home/deploy/.gem/ruby/2.1.0
- GEM CONFIGURATION:
- :update_sources => true
- :verbose => true
- :backtrace => false
- :bulk_threshold => 1000
- "gem" => "--no-ri --no-rdoc"
- REMOTE SOURCES:
- https://rubygems.org/
- SHELL PATH:
- /home/deploy/.rbenv/versions/2.1.2/bin
- /home/deploy/.rbenv/libexec
- /home/deploy/.rbenv/plugins/ruby-build/bin
- /home/deploy/.rbenv/plugins/ruby-build/bin
- /home/deploy/.rbenv/shims
- /home/deploy/.rbenv/bin
- /usr/local/sbin
- /usr/local/bin
- /usr/sbin
- /usr/bin
- /sbin
- /bin
- /usr/games
- /usr/local/games
想法?思考?给我的东西尝试?我很困难......