LoginSignup
1
2

More than 5 years have passed since last update.

rake db:migrate で rake aborted!になる(rake のバージョンが違う)場合の解決法

Last updated at Posted at 2016-10-05

rake logdb:migrateを実行

$rake logdb:migrate

rake aborted!
Gem::LoadError: You have already activated rake 11.2.2, but your Gemfile requires rake 10.5.0. Prepending `bundle exec` to your command may solve this.

要求されているrakeのバージョンが違う模様。

バージョンを指定してrakeを実行

$ rake _10.5.0_ db:migrate

毎回バージョンを指定するのは面倒くさい・・・。

使用しないrakeのバージョンをuninstallする

$ gem uninstall rake

Select gem to uninstall:
 1. rake-10.4.2
 2. rake-10.5.0
 3. rake-11.2.2
 4. All versions
> 3
Successfully uninstalled rake-11.2.2
1
2
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
2