Permalink
Browse files

Revert "Revert "Revert "Switched to newer rdoc and gem package tasks …

…(and their requires)."""

We need an old RDoc to be able to generate the API.

This reverts commit af7da4d.
  • Loading branch information...
1 parent 3773c2f commit b662deb93f8a8c25fec38ce2cdccd2f075dda688 @fxn fxn committed Apr 4, 2013
Showing with 39 additions and 28 deletions.
  1. +2 −2 Rakefile
  2. +6 −4 actionmailer/Rakefile
  3. +6 −4 actionpack/Rakefile
  4. +2 −2 activemodel/Rakefile
  5. +6 −4 activerecord/Rakefile
  6. +6 −4 activeresource/Rakefile
  7. +5 −4 activesupport/Rakefile
  8. +6 −4 railties/Rakefile
View
@@ -1,5 +1,5 @@
require 'rake'
-require 'rdoc/task'
+require 'rake/rdoctask'
env = %(PKG_BUILD="#{ENV['PKG_BUILD']}") if ENV['PKG_BUILD']
@@ -23,7 +23,7 @@ end
desc "Generate documentation for the Rails framework"
-RDoc::Task.new do |rdoc|
+Rake::RDocTask.new do |rdoc|
rdoc.rdoc_dir = 'doc/rdoc'
rdoc.title = "Ruby on Rails Documentation"
rdoc.main = "railties/README"
View
@@ -1,9 +1,9 @@
require 'rubygems'
require 'rake'
require 'rake/testtask'
-require 'rdoc/task'
+require 'rake/rdoctask'
require 'rake/packagetask'
-require 'rubygems/package_task'
+require 'rake/gempackagetask'
require File.join(File.dirname(__FILE__), 'lib', 'action_mailer', 'version')
PKG_BUILD = ENV['PKG_BUILD'] ? '.' + ENV['PKG_BUILD'] : ''
@@ -29,7 +29,7 @@ Rake::TestTask.new { |t|
# Generate the RDoc documentation
-RDoc::Task.new { |rdoc|
+Rake::RDocTask.new { |rdoc|
rdoc.rdoc_dir = 'doc'
rdoc.title = "Action Mailer -- Easy email delivery and testing"
rdoc.options << '--line-numbers' << '--inline-source' << '-A cattr_accessor=object'
@@ -56,15 +56,17 @@ spec = Gem::Specification.new do |s|
s.add_dependency('actionpack', '= 2.3.18' + PKG_BUILD)
+ s.has_rdoc = true
s.requirements << 'none'
s.require_path = 'lib'
+ s.autorequire = 'action_mailer'
s.files = [ "Rakefile", "install.rb", "README", "CHANGELOG", "MIT-LICENSE" ]
s.files = s.files + Dir.glob( "lib/**/*" ).delete_if { |item| item.include?( "\.svn" ) }
s.files = s.files + Dir.glob( "test/**/*" ).delete_if { |item| item.include?( "\.svn" ) }
end
-Gem::PackageTask.new(spec) do |p|
+Rake::GemPackageTask.new(spec) do |p|
p.gem_spec = spec
p.need_tar = true
p.need_zip = true
View
@@ -1,9 +1,9 @@
require 'rubygems'
require 'rake'
require 'rake/testtask'
-require 'rdoc/task'
+require 'rake/rdoctask'
require 'rake/packagetask'
-require 'rubygems/package_task'
+require 'rake/gempackagetask'
require File.join(File.dirname(__FILE__), 'lib', 'action_pack', 'version')
PKG_BUILD = ENV['PKG_BUILD'] ? '.' + ENV['PKG_BUILD'] : ''
@@ -45,7 +45,7 @@ end
# Genereate the RDoc documentation
-RDoc::Task.new { |rdoc|
+Rake::RDocTask.new { |rdoc|
rdoc.rdoc_dir = 'doc'
rdoc.title = "Action Pack -- On rails from request to response"
rdoc.options << '--line-numbers' << '--inline-source'
@@ -76,20 +76,22 @@ spec = Gem::Specification.new do |s|
s.rubyforge_project = "actionpack"
s.homepage = "http://www.rubyonrails.org"
+ s.has_rdoc = true
s.requirements << 'none'
s.add_dependency('activesupport', '= 2.3.18' + PKG_BUILD)
s.add_dependency('rack', '~> 1.1.0')
s.require_path = 'lib'
+ s.autorequire = 'action_controller'
s.files = [ "Rakefile", "install.rb", "README", "RUNNING_UNIT_TESTS", "CHANGELOG", "MIT-LICENSE" ]
dist_dirs.each do |dir|
s.files = s.files + Dir.glob( "#{dir}/**/*" ).delete_if { |item| item.include?( "\.svn" ) }
end
end
-Gem::PackageTask.new(spec) do |p|
+Rake::GemPackageTask.new(spec) do |p|
p.gem_spec = spec
p.need_tar = true
p.need_zip = true
View
@@ -1,7 +1,7 @@
#!/usr/bin/env ruby
require 'rake'
require 'rake/testtask'
-require 'rdoc/task'
+require 'rake/rdoctask'
task :default => :test
@@ -13,7 +13,7 @@ Rake::TestTask.new do |t|
end
# Generate the RDoc documentation
-RDoc::Task.new do |rdoc|
+Rake::RDocTask.new do |rdoc|
rdoc.rdoc_dir = 'doc'
rdoc.title = "Active Model"
rdoc.options << '--line-numbers' << '--inline-source' << '-A cattr_accessor=object'
View
@@ -1,9 +1,9 @@
require 'rubygems'
require 'rake'
require 'rake/testtask'
-require 'rdoc/task'
+require 'rake/rdoctask'
require 'rake/packagetask'
-require 'rubygems/package_task'
+require 'rake/gempackagetask'
require File.join(File.dirname(__FILE__), 'lib', 'active_record', 'version')
require File.expand_path(File.dirname(__FILE__)) + "/test/config"
@@ -157,7 +157,7 @@ task :rebuild_frontbase_databases => 'frontbase:rebuild_databases'
# Generate the RDoc documentation
-RDoc::Task.new { |rdoc|
+Rake::RDocTask.new { |rdoc|
rdoc.rdoc_dir = 'doc'
rdoc.title = "Active Record -- Object-relation mapping put on rails"
rdoc.options << '--line-numbers' << '--inline-source' << '-A cattr_accessor=object'
@@ -199,7 +199,9 @@ spec = Gem::Specification.new do |s|
s.files.delete FIXTURES_ROOT + "/fixture_database.sqlite3"
s.files.delete FIXTURES_ROOT + "/fixture_database_2.sqlite3"
s.require_path = 'lib'
+ s.autorequire = 'active_record'
+ s.has_rdoc = true
s.extra_rdoc_files = %w( README )
s.rdoc_options.concat ['--main', 'README']
@@ -209,7 +211,7 @@ spec = Gem::Specification.new do |s|
s.rubyforge_project = "activerecord"
end
-Gem::PackageTask.new(spec) do |p|
+Rake::GemPackageTask.new(spec) do |p|
p.gem_spec = spec
p.need_tar = true
p.need_zip = true
View
@@ -1,9 +1,9 @@
require 'rubygems'
require 'rake'
require 'rake/testtask'
-require 'rdoc/task'
+require 'rake/rdoctask'
require 'rake/packagetask'
-require 'rubygems/package_task'
+require 'rake/gempackagetask'
require File.join(File.dirname(__FILE__), 'lib', 'active_resource', 'version')
@@ -38,7 +38,7 @@ Rake::TestTask.new { |t|
# Generate the RDoc documentation
-RDoc::Task.new { |rdoc|
+Rake::RDocTask.new { |rdoc|
rdoc.rdoc_dir = 'doc'
rdoc.title = "Active Resource -- Object-oriented REST services"
rdoc.options << '--line-numbers' << '--inline-source' << '-A cattr_accessor=object'
@@ -69,7 +69,9 @@ spec = Gem::Specification.new do |s|
s.add_dependency('activesupport', '= 2.3.18' + PKG_BUILD)
s.require_path = 'lib'
+ s.autorequire = 'active_resource'
+ s.has_rdoc = true
s.extra_rdoc_files = %w( README )
s.rdoc_options.concat ['--main', 'README']
@@ -79,7 +81,7 @@ spec = Gem::Specification.new do |s|
s.rubyforge_project = "activeresource"
end
-Gem::PackageTask.new(spec) do |p|
+Rake::GemPackageTask.new(spec) do |p|
p.gem_spec = spec
p.need_tar = true
p.need_zip = true
View
@@ -1,6 +1,6 @@
require 'rake/testtask'
-require 'rdoc/task'
-require 'rubygems/package_task'
+require 'rake/rdoctask'
+require 'rake/gempackagetask'
require File.join(File.dirname(__FILE__), 'lib', 'active_support', 'version')
@@ -27,7 +27,7 @@ dist_dirs = [ "lib", "test"]
# Genereate the RDoc documentation
-RDoc::Task.new { |rdoc|
+Rake::RDocTask.new { |rdoc|
rdoc.rdoc_dir = 'doc'
rdoc.title = "Active Support -- Utility classes and standard library extensions from Rails"
rdoc.options << '--line-numbers' << '--inline-source'
@@ -48,14 +48,15 @@ spec = Gem::Specification.new do |s|
s.files = [ "CHANGELOG", "README" ] + Dir.glob( "lib/**/*" ).delete_if { |item| item.include?( "\.svn" ) }
s.require_path = 'lib'
+ s.has_rdoc = true
s.author = "David Heinemeier Hansson"
s.email = "david@loudthinking.com"
s.homepage = "http://www.rubyonrails.org"
s.rubyforge_project = "activesupport"
end
-Gem::PackageTask.new(spec) do |p|
+Rake::GemPackageTask.new(spec) do |p|
p.gem_spec = spec
p.need_tar = true
p.need_zip = true
View
@@ -1,7 +1,7 @@
require 'rake'
require 'rake/testtask'
-require 'rdoc/task'
-require 'rubygems/package_task'
+require 'rake/rdoctask'
+require 'rake/gempackagetask'
require 'date'
require 'rbconfig'
@@ -267,7 +267,7 @@ task :generate_app_doc do
system %{cd #{PKG_DESTINATION}; rake doc:app}
end
-RDoc::Task.new { |rdoc|
+Rake::RDocTask.new { |rdoc|
rdoc.rdoc_dir = 'doc'
rdoc.title = "Railties -- Gluing the Engine to the Rails"
rdoc.options << '--line-numbers' << '--inline-source' << '--accessor' << 'cattr_accessor=object'
@@ -320,19 +320,21 @@ spec = Gem::Specification.new do |s|
s.add_dependency('activeresource', '= 2.3.18' + PKG_BUILD)
s.rdoc_options << '--exclude' << '.'
+ s.has_rdoc = false
s.files = PKG_FILES
s.require_path = 'lib'
s.bindir = "bin" # Use these for applications.
s.executables = ["rails"]
+ s.default_executable = "rails"
s.author = "David Heinemeier Hansson"
s.email = "david@loudthinking.com"
s.homepage = "http://www.rubyonrails.org"
s.rubyforge_project = "rails"
end
-Gem::PackageTask.new(spec) do |pkg|
+Rake::GemPackageTask.new(spec) do |pkg|
pkg.gem_spec = spec
end

0 comments on commit b662deb

Please sign in to comment.