Include Active Resource instead of Action Web Service [DHH]

git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6550 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
This commit is contained in:
David Heinemeier Hansson 2007-04-23 18:55:54 +00:00
parent 52a9e5089c
commit df41c7cb61
7 changed files with 24 additions and 23 deletions

View File

@ -55,22 +55,18 @@ dist_dirs = [ "lib", "test", "examples", "dev-utils" ]
spec = Gem::Specification.new do |s| spec = Gem::Specification.new do |s|
s.name = PKG_NAME s.name = PKG_NAME
s.version = PKG_VERSION s.version = PKG_VERSION
s.summary = "Implements the ActiveRecord pattern for ORM." s.summary = "Think Active Record for web resources."
s.description = %q{Implements the ActiveRecord pattern (Fowler, PoEAA) for ORM. It ties database tables and classes together for business objects, like Customer or Subscription, that can find, save, and destroy themselves without resorting to manual SQL.} s.description = %q{Wraps web resources in model classes that can be manipulated through XML over REST.}
s.files = [ "Rakefile", "install.rb", "README", "RUNNING_UNIT_TESTS", "CHANGELOG" ] s.files = [ "Rakefile", "install.rb", "README", "RUNNING_UNIT_TESTS", "CHANGELOG" ]
dist_dirs.each do |dir| dist_dirs.each do |dir|
s.files = s.files + Dir.glob( "#{dir}/**/*" ).delete_if { |item| item.include?( "\.svn" ) } s.files = s.files + Dir.glob( "#{dir}/**/*" ).delete_if { |item| item.include?( "\.svn" ) }
end end
s.add_dependency('activesupport', '= 1.3.1' + PKG_BUILD) s.add_dependency('activesupport', '= 1.4.2' + PKG_BUILD)
s.files.delete "test/fixtures/fixture_database.sqlite"
s.files.delete "test/fixtures/fixture_database_2.sqlite"
s.files.delete "test/fixtures/fixture_database.sqlite3"
s.files.delete "test/fixtures/fixture_database_2.sqlite3"
s.require_path = 'lib' s.require_path = 'lib'
s.autorequire = 'active_record' s.autorequire = 'active_resource'
s.has_rdoc = true s.has_rdoc = true
s.extra_rdoc_files = %w( README ) s.extra_rdoc_files = %w( README )
@ -79,7 +75,7 @@ spec = Gem::Specification.new do |s|
s.author = "David Heinemeier Hansson" s.author = "David Heinemeier Hansson"
s.email = "david@loudthinking.com" s.email = "david@loudthinking.com"
s.homepage = "http://www.rubyonrails.org" s.homepage = "http://www.rubyonrails.org"
s.rubyforge_project = "activerecord" s.rubyforge_project = "activeresource"
end end
Rake::GemPackageTask.new(spec) do |p| Rake::GemPackageTask.new(spec) do |p|
@ -91,7 +87,7 @@ end
task :lines do task :lines do
lines, codelines, total_lines, total_codelines = 0, 0, 0, 0 lines, codelines, total_lines, total_codelines = 0, 0, 0, 0
for file_name in FileList["lib/active_record/**/*.rb"] for file_name in FileList["lib/active_resource/**/*.rb"]
next if file_name =~ /vendor/ next if file_name =~ /vendor/
f = File.open(file_name) f = File.open(file_name)

View File

@ -1,7 +1,7 @@
module ActiveResource module ActiveResource
module VERSION #:nodoc: module VERSION #:nodoc:
MAJOR = 0 MAJOR = 0
MINOR = 5 MINOR = 9
TINY = 0 TINY = 0
STRING = [MAJOR, MINOR, TINY].join('.') STRING = [MAJOR, MINOR, TINY].join('.')

View File

@ -4,7 +4,7 @@ unless ARGV.first == "no_build"
build_number = build_number = `svn log -q -rhead http://dev.rubyonrails.org/svn/rails`.scan(/r([0-9]*)/).first.first.to_i build_number = build_number = `svn log -q -rhead http://dev.rubyonrails.org/svn/rails`.scan(/r([0-9]*)/).first.first.to_i
end end
%w( actionwebservice actionmailer actionpack activerecord railties activesupport ).each do |pkg| %w( activeresource actionmailer actionpack activerecord railties activesupport ).each do |pkg|
puts "Pushing: #{pkg} (#{build_number})" puts "Pushing: #{pkg} (#{build_number})"
if build_number if build_number
`cd #{pkg} && rm -rf pkg && PKG_BUILD=#{build_number} rake pgem && cd ..` `cd #{pkg} && rm -rf pkg && PKG_BUILD=#{build_number} rake pgem && cd ..`

View File

@ -1,5 +1,11 @@
*SVN* *SVN*
* Include Active Resource instead of Action Web Service [DHH] You can add AWS back with this in config/environment.rb:
config.load_paths += %W( #{RAILS_ROOT}/vendor/rails/actionwebservice/lib )
...or just gem 'actionwebservice'
* Give generate scaffold a more descriptive database message. Closes #7316 [jeremymcanally] * Give generate scaffold a more descriptive database message. Closes #7316 [jeremymcanally]
* Canonicalize RAILS_ROOT by using File.expand_path on Windows, which doesn't have to worry about symlinks, and Pathname#realpath elsewhere, which respects symlinks in relative paths but is incompatible with Windows. #6755 [Jeremy Kemper, trevor] * Canonicalize RAILS_ROOT by using File.expand_path on Windows, which doesn't have to worry about symlinks, and Pathname#realpath elsewhere, which respects symlinks in relative paths but is incompatible with Windows. #6755 [Jeremy Kemper, trevor]

View File

@ -313,7 +313,7 @@ spec = Gem::Specification.new do |s|
s.add_dependency('activerecord', '= 1.15.3' + PKG_BUILD) s.add_dependency('activerecord', '= 1.15.3' + PKG_BUILD)
s.add_dependency('actionpack', '= 1.13.3' + PKG_BUILD) s.add_dependency('actionpack', '= 1.13.3' + PKG_BUILD)
s.add_dependency('actionmailer', '= 1.3.3' + PKG_BUILD) s.add_dependency('actionmailer', '= 1.3.3' + PKG_BUILD)
s.add_dependency('actionwebservice', '= 1.2.3' + PKG_BUILD) s.add_dependency('actionresource', '= 0.9.0' + PKG_BUILD)
s.rdoc_options << '--exclude' << '.' s.rdoc_options << '--exclude' << '.'
s.has_rdoc = false s.has_rdoc = false

View File

@ -14,7 +14,7 @@ Rails::Initializer.run do |config|
# Settings in config/environments/* take precedence over those specified here # Settings in config/environments/* take precedence over those specified here
# Skip frameworks you're not going to use (only works if using vendor/rails) # Skip frameworks you're not going to use (only works if using vendor/rails)
# config.frameworks -= [ :action_web_service, :action_mailer ] # config.frameworks -= [ :active_resource, :action_mailer ]
# Only load the plugins named here, by default all plugins in vendor/plugins are loaded # Only load the plugins named here, by default all plugins in vendor/plugins are loaded
# config.plugins = %W( exception_notification ssl_requirement ) # config.plugins = %W( exception_notification ssl_requirement )

View File

@ -23,7 +23,7 @@ module Rails
# through the block running: # through the block running:
# #
# Rails::Initializer.run do |config| # Rails::Initializer.run do |config|
# config.frameworks -= [ :action_web_service ] # config.frameworks -= [ :action_mailer ]
# end # end
# #
# This will use the default configuration options from Rails::Configuration, # This will use the default configuration options from Rails::Configuration,
@ -379,12 +379,12 @@ module Rails
# A stub for setting options on ActionView::Base # A stub for setting options on ActionView::Base
attr_accessor :action_view attr_accessor :action_view
# A stub for setting options on ActionWebService::Base
attr_accessor :action_web_service
# A stub for setting options on ActiveRecord::Base # A stub for setting options on ActiveRecord::Base
attr_accessor :active_record attr_accessor :active_record
# A stub for setting options on ActiveRecord::Base
attr_accessor :active_resource
# Whether or not to use the breakpoint server (boolean) # Whether or not to use the breakpoint server (boolean)
attr_accessor :breakpoint_server attr_accessor :breakpoint_server
@ -560,8 +560,8 @@ module Rails
actionpack/lib actionpack/lib
activesupport/lib activesupport/lib
activerecord/lib activerecord/lib
activeresource/lib
actionmailer/lib actionmailer/lib
actionwebservice/lib
).map { |dir| "#{framework_root_path}/#{dir}" }.select { |dir| File.directory?(dir) } ).map { |dir| "#{framework_root_path}/#{dir}" }.select { |dir| File.directory?(dir) }
end end
@ -571,7 +571,7 @@ module Rails
end end
def default_frameworks def default_frameworks
[ :active_record, :action_controller, :action_view, :action_mailer, :action_web_service ] [ :active_record, :action_controller, :action_view, :action_mailer, :active_resource ]
end end
def default_load_paths def default_load_paths
@ -590,7 +590,6 @@ module Rails
app/controllers app/controllers
app/helpers app/helpers
app/services app/services
app/apis
components components
config config
lib lib