diff options
author | José Valim <jose.valim@gmail.com> | 2010-03-30 14:41:22 +0200 |
---|---|---|
committer | José Valim <jose.valim@gmail.com> | 2010-03-30 14:41:58 +0200 |
commit | 41b45d56553316f175660fe6e2923409adee37e2 (patch) | |
tree | e1cbabec9bc7417b98a718419565dbce10b9dd9b | |
parent | ffcd44144a10d41e175dedfcebb48e6b275726a8 (diff) | |
download | rails-41b45d56553316f175660fe6e2923409adee37e2.tar.gz rails-41b45d56553316f175660fe6e2923409adee37e2.tar.bz2 rails-41b45d56553316f175660fe6e2923409adee37e2.zip |
Bring rdoc tasks back to plugins.
-rw-r--r-- | railties/lib/rails/generators/rails/plugin/templates/Rakefile.tt | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/railties/lib/rails/generators/rails/plugin/templates/Rakefile.tt b/railties/lib/rails/generators/rails/plugin/templates/Rakefile.tt index e94c0bfc77..733e321c94 100644 --- a/railties/lib/rails/generators/rails/plugin/templates/Rakefile.tt +++ b/railties/lib/rails/generators/rails/plugin/templates/Rakefile.tt @@ -1,10 +1,23 @@ +require 'rake' require 'rake/testtask' +require 'rake/rdoctask' desc 'Default: run unit tests.' task :default => :test desc 'Test the <%= file_name %> plugin.' Rake::TestTask.new(:test) do |t| + t.libs << 'lib' t.libs << 'test' t.pattern = 'test/**/*_test.rb' + t.verbose = true end + +desc 'Generate documentation for the <%= file_name %> plugin.' +Rake::RDocTask.new(:rdoc) do |rdoc| + rdoc.rdoc_dir = 'rdoc' + rdoc.title = '<%= class_name %>' + rdoc.options << '--line-numbers' << '--inline-source' + rdoc.rdoc_files.include('README') + rdoc.rdoc_files.include('lib/**/*.rb') +end
\ No newline at end of file |