我在堆栈溢出中找到了这篇文章rubymine 错误:您已经激活了 rake 10.0.3,但您的 Gemfile 需要 rake 0.9.6。使用bundle exec 可以解决这个问题 https://stackoverflow.com/questions/15712009/rubymine-error-you-have-already-activated-rake-10-0-3-but-your-gemfile-require
提供了两种可能的解决方案:
- 忽略项目设置中的全局 gem 路径
- 卸载有问题的 gem
到目前为止,这些解决方案都不适合我:我尝试忽略全局 gem 路径,但我不断收到相同的错误消息。关于卸载 gem,这是不可能的,因为我还有其他项目依赖于较新的 rake 版本,我不想弄乱它。
有什么方法可以强制 RubyMine 在 rake 任务之前使用bundle exec?
Go to Run -> Edit Configurations, select the BUNDLER tab, and click the checkbox "Run the script in context of the bundle (bundle exec)"
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)