mislav / hanna

More than just a new RDoc template
MIT License
234 stars 40 forks source link

undefined method `rdoc' #12

Closed dreamcat4 closed 14 years ago

dreamcat4 commented 14 years ago
$ gem install mislav-hanna  --no-rdoc --no-ri 
Successfully installed mislav-hanna-0.1.11
1 gem installed

$ rake rdoc --trace               
(in /Users/id/tmp/yamldoc)
rake aborted!
undefined method `rdoc' for ["README.rdoc", "LICENSE", "CHANGELOG.rdoc", "lib/yamldoc.rb"]:Rake::FileList
/Users/id/tmp/yamldoc/Rakefile:15
/Users/id/.gem/ruby/1.8/gems/rake-0.8.7/lib/rake/rdoctask.rb:106:in `initialize'
/Users/id/tmp/yamldoc/Rakefile:14:in `new'
/Users/id/tmp/yamldoc/Rakefile:14

$ head -18 Rakefile
require 'rubygems'
require 'rake'

begin
  hanna_dir = '/Users/mislav/Projects/Hanna/lib'
  $:.unshift hanna_dir if File.exists? hanna_dir
  require 'hanna/rdoctask'
rescue LoadError
  require 'rake'
  require 'rake/rdoctask'
end

desc 'Generate RDoc documentation for YamlDoc.'
Rake::RDocTask.new(:rdoc) do |rdoc|
  rdoc.rdoc_files.include('README.rdoc', 'LICENSE', 'CHANGELOG.rdoc').
    include('lib/**/*.rb').
    exclude('lib/class_attributes.rb').
dreamcat4 commented 14 years ago

But its exactly copied from mislav's will_paginate rake task:

http://github.com/mislav/will_paginate/blob/master/Rakefile

dreamcat4 commented 14 years ago

Ah it was indeed a typo:

exclude('lib/class_attributes.rb').

Should not be ended in a dot. Closed.

mislav commented 14 years ago

Yeah, the error didn't look like it's coming from Hanna at all