markbates / mack-more

All the extra stuff you could want for the Mack Framework.

This URL has Read+Write access

mack-more / common_rake_tasks / rdoc.rake
100644 18 lines (17 sloc) 0.533 kb
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
Rake::RDocTask.new do |rd|
  rd.main = "README"
  files = Dir.glob("**/*.rb")
  files = files.collect {|f| f unless f.match("test/") || f.match("doc/") || f.match("spec/") || f.match('gems/') }.compact
  files << "README"
  rd.rdoc_files = files
  rd.rdoc_dir = "doc"
  rd.options << "--line-numbers"
  rd.options << "--inline-source"
  rd.options << '--exclude=gems/'
  rd.title = @gem_spec.name
end
 
task :clean_rdoc do
  require 'fileutils'
  FileUtils.rm_rf('pkg', :verbose => true)
  FileUtils.rm_rf('doc', :verbose => true)
end