Rake uninitialized constant RDoc::RDoc

谁说我不能喝 提交于 2019-12-21 04:29:18

问题


When ever I run make I get this 'uninitialized constant RDoc::RDoc' error

rake -T (in Main) rake aborted! uninitialized constant RDoc::RDoc C:/Ruby186/lib/ruby/gems/1.8/gems/rake-0.8.7/lib/rake.rb:2383:in `raw_load_rakefile' (See full trace by running task with --trace)

--edit

Running --trace it seems the only non rails code is from rdoc_rails. Since other people seem to be able to run it fine I assume I am missing a gem or plugin but I can't figure out which.


回答1:


It looks like i have to apply both solutions for Rails (2.3.12)

  1. Install rake 0.9.2
  2. Install RDoc 2.4.3
gem install rdoc --version=2.4.3
gem update rake

I found side-effect of this solution, It caused another error like - Ruby on Rails and Rake problems: uninitialized constant Rake::DSL




回答2:


In my case, it was a question of updating rake: sudo gem update rake




回答3:


rdoc_rails required RDoc of 2.4.3 which isn't the latest so you have to specifically install it.



来源:https://stackoverflow.com/questions/2993435/rake-uninitialized-constant-rdocrdoc

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!