Skip to content

Commit

Permalink
rdoc AND yardoc
Browse files Browse the repository at this point in the history
  • Loading branch information
leikind committed Aug 28, 2015
1 parent 3f8de97 commit b9086ea
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 7 deletions.
26 changes: 19 additions & 7 deletions Rakefile
Original file line number Diff line number Diff line change
Expand Up @@ -26,21 +26,33 @@ RuboCop::RakeTask.new(:rubocop) do |task|
task.fail_on_error = false
end

desc 'Run RSpec with code coverage'
task :coverage do
ENV['COVERAGE'] = 'true'
Rake::Task['spec'].execute
end


require 'yard'
require 'yard/rake/yardoc_task'
desc 'Generate documentation for the wice_grid plugin.'
YARD::Rake::YardocTask.new(:rdoc) do |t|
desc 'Generate YARDOC documentation for the plugin'
YARD::Rake::YardocTask.new(:yardoc) do |t|
OTHER_PATHS = %w()

t.files = ['lib/**/*.rb', OTHER_PATHS]
t.options = %w(--main=README.md --file TODO.md,CHANGELOG.md,SAVED_QUERIES_HOWTO.md,MIT-LICENSE)
t.stats_options = ['--list-undoc']
end

desc 'Run RSpec with code coverage'
task :coverage do
ENV['COVERAGE'] = 'true'
Rake::Task['spec'].execute
gem 'rdoc'
require 'rdoc/task'
Rake::RDocTask.new(:rdoc) do |rdoc|
rdoc.rdoc_dir = 'rdoc'
rdoc.title = 'WiceGrid'
rdoc.options << '--line-numbers' << '--inline-source'
rdoc.rdoc_files.include('README.md')
rdoc.rdoc_files.include('SAVED_QUERIES_HOWTO.md')
rdoc.rdoc_files.include('CHANGELOG.md')
rdoc.rdoc_files.include('lib/**/*.rb')
end

task default: [:rubocop, :spec, :rdoc]
1 change: 1 addition & 0 deletions wice_grid.gemspec
Original file line number Diff line number Diff line change
Expand Up @@ -29,4 +29,5 @@ Gem::Specification.new do |s|
s.add_development_dependency('rubocop', '~> 0.33')
s.add_development_dependency('coveralls', '~> 0.8.2')
s.add_development_dependency('sqlite3', '~> 1.3')
s.add_development_dependency('rdoc', '~> 4.2.0')
end

0 comments on commit b9086ea

Please sign in to comment.