我正在运行bundle install --local
并得到以下错误:
Your bundle is locked to rake (11.2.2), but that version could not be found in
any of the sources listed in your Gemfile. If you haven't changed sources, that
means the author of rake (11.2.2) has removed it. You'll need to update your
bundle to a different version of rake (11.2.2) that hasn't been removed in order to install.
无法理解需要做什么。如有任何帮助,不胜感激。
试着运行这些命令
gem install rubygems-bundler
gem regenerate_binstubs
我在使用Jenkins时也遇到了这个问题,所以下面是帮助我的方法:
首先通过控制台到您的作业目录:
cd /var/lib/jenkins/workspace/<your-job-name>
如果你不确定Jenkins在哪里存储你的项目,使用pwd
命令在你的bash脚本。
在这个目录中,找到你的Gemfile。锁定并删除
rm Gemfile.lock
然后尝试运行bundle,就像你通常在控制台
中做的那样bundle install
看到你的包工作。