我正在为我的项目使用Ruby Enterprise Edition 。 当我通过运行命令rake -T检查我所有的rake任务时 ,我收到以下错误消息:
You have already activated rake 0.9.2.2, but your Gemfile requires rake 0.9.2. Using bundle exec may solve this.错误消息意味着我可以使用bundle exec来解决问题,但我不知道如何? 那么,如何摆脱这个错误信息呢?
- - - - - - - - - - - - - - - 更多 - - - - - - - - - - --------
我更喜欢更新我的Gemfile而不是运行bundle exec rake -T 。 但是当我打开我的项目Gemfile时,我没有在我的Gemfile中看到rake 0.9.2,为什么错误消息抱怨我拥有它? 哪里可以找到我定义耙0.9.2的地方?
I am using Ruby Enterprise Edition for my project. When I check all my rake task by run the command rake -T , I got the following error message:
You have already activated rake 0.9.2.2, but your Gemfile requires rake 0.9.2. Using bundle exec may solve this.The error message implies that I can use bundle exec to solve the problem, but I am not sure how? So, how to get rid of this error message?
------------------------------ more ---------------------------
I prefer to update my Gemfile instead of run bundle exec rake -T. But when I open my project Gemfile, I did not see rake 0.9.2 in my Gemfile, why the error message complains that I have it? Where could be the place I defined rake 0.9.2??
最满意答案
运行bundle exec rake -T ,这可以确保在Gemfile中指定的rake版本正在运行,而不是另一个版本。
或者,更新您的Gemfile。
Run bundle exec rake -T, this ensures that the version of rake that is specified in your Gemfile is running, not another version.
Alternatively, update your Gemfile.
更多推荐
发布评论