Ruby rake db:create 1.9.1/rake.rb:2482:in `const_missing'

来源:互联网 发布:江苏学信学院传销 知乎 编辑:程序博客网 时间:2024/06/05 08:44
I installed gem install rake -v=0.9.2 (I had the 0.9.1 gem)
removed the 0.9.1 with gem uninstall rake -v=0.9.1
updated with bundle update
then the db:migrate showed a warning, WARNING: Global access to Rake DSL methods is deprecated. Please....


It was solved by adding the following to the Rake file.


module ::YourApplicationName  
  class Application
    include Rake::DSL
  end
end
I ommited the module ::RakeFileUtils extend Rake::FileUtilsExtend option sugested by @databyte.


It means that the Rake gem 0.9.2 works fine!
原创粉丝点击