本文介绍了rake db:migrate 不起作用(Rails 4.0.4)的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我在 Rails 4.0.4/Ruby 2.1.0 上有一个新应用.我做的第一件事是添加 Devise gem.当我想运行 rake db:migrate 时,它什么也不做.没有错误,但没有执行迁移.
I have a new app on Rails 4.0.4 / Ruby 2.1.0. The first thing I did was adding Devise gem. When I want to run rake db:migrate, it just does nothing. No error, but the migration isn't executed.
你能帮我处理这个案子吗?我找不到问题出在哪里.
Could you please help me what to do with this case? I can't find where is the problem.
谢谢!彼得
推荐答案好的,所以问题是设计生成器生成了带有迁移的.txt"文件而不是.rb"文件.奇怪,但更改扩展名解决了它.
OK, so the problem was that Devise generator generated ".txt" file with migration instead of ".rb" file. Strange, but changing extension solved it.
更多推荐
rake db:migrate 不起作用(Rails 4.0.4)
发布评论