From d5d96f2d42ca8b1163502ef20ebc1326df752020 Mon Sep 17 00:00:00 2001 From: Thibaut Courouble Date: Fri, 1 Jul 2016 16:39:45 -0400 Subject: [PATCH] Update Ruby on Rails documentation (5.0.0, 4.2.6, 4.1.15) --- lib/docs/filters/rails/entries.rb | 50 ++++++++++++++++--------------- lib/docs/scrapers/rdoc/rails.rb | 29 ++++++------------ 2 files changed, 35 insertions(+), 44 deletions(-) diff --git a/lib/docs/filters/rails/entries.rb b/lib/docs/filters/rails/entries.rb index 2bf46685..fbb8a535 100644 --- a/lib/docs/filters/rails/entries.rb +++ b/lib/docs/filters/rails/entries.rb @@ -9,32 +9,34 @@ module Docs /\AActiveRecord.+Assoc/ => 'ActiveRecord/Associations', /\AActiveRecord.+Attribute/ => 'ActiveRecord/Attributes', /\AActiveRecord.+ConnectionAdapters/ => 'ActiveRecord/Connection', - /\AActiveSupport.+(Subscriber|Notifications)/ => 'ActiveSupport/Instrumentation', - /\A(False|Nil|True)Class/ => 'Boolean' } + /\AActiveSupport.+(Subscriber|Notifications)/ => 'ActiveSupport/Instrumentation' } TYPE_BY_NAME_STARTS_WITH = { - 'ActionDispatch::Integration' => 'Testing', - 'ActionDispatch::Request' => 'ActionDispatch/Request', - 'ActionDispatch::Response' => 'ActionDispatch/Response', - 'ActionDispatch::Routing' => 'ActionDispatch/Routing', - 'ActionView::Helpers' => 'ActionView/Helpers', - 'ActiveModel::Errors' => 'ActiveModel/Validation', - 'ActiveModel::Valid' => 'ActiveModel/Validation', - 'ActiveRecord::Batches' => 'ActiveModel/Query', - 'ActiveRecord::Calculations' => 'ActiveModel/Query', - 'ActiveRecord::Connection' => 'ActiveModel/Connection', - 'ActiveRecord::FinderMethods' => 'ActiveModel/Query', - 'ActiveRecord::Query' => 'ActiveModel/Query', - 'ActiveRecord::Relation' => 'ActiveModel/Relation', - 'ActiveRecord::Result' => 'ActiveModel/Connection', - 'ActiveRecord::Scoping' => 'ActiveModel/Query', - 'ActiveRecord::SpawnMethods' => 'ActiveModel/Query', - 'ActiveSupport::Cach' => 'ActiveSupport/Caching', - 'ActiveSupport::Inflector' => 'ActiveSupport/Inflector', - 'ActiveSupport::Time' => 'ActiveSupport/TimeZones', - 'Rails::Application' => 'Rails/Application', - 'Rails::Engine' => 'Rails/Engine', - 'Rails::Railtie' => 'Rails/Railtie' } + 'ActionController::Parameters' => 'ActionController/Parameters', + 'ActionDispatch::Integration' => 'Testing', + 'ActionDispatch::Request' => 'ActionDispatch/Request', + 'ActionDispatch::Response' => 'ActionDispatch/Response', + 'ActionDispatch::Routing' => 'ActionDispatch/Routing', + 'ActionView::Helpers' => 'ActionView/Helpers', + 'ActiveModel::Errors' => 'ActiveModel/Validation', + 'ActiveModel::Valid' => 'ActiveModel/Validation', + 'ActiveRecord::Batches' => 'ActiveRecord/Query', + 'ActiveRecord::Calculations' => 'ActiveRecord/Query', + 'ActiveRecord::Connection' => 'ActiveRecord/Connection', + 'ActiveRecord::FinderMethods' => 'ActiveRecord/Query', + 'ActiveRecord::Migra' => 'ActiveRecord/Migration', + 'ActiveRecord::Query' => 'ActiveRecord/Query', + 'ActiveRecord::Relation' => 'ActiveRecord/Relation', + 'ActiveRecord::Result' => 'ActiveRecord/Connection', + 'ActiveRecord::Scoping' => 'ActiveRecord/Query', + 'ActiveRecord::SpawnMethods' => 'ActiveRecord/Query', + 'ActiveSupport::Cach' => 'ActiveSupport/Caching', + 'ActiveSupport::Inflector' => 'ActiveSupport/Inflector', + 'ActiveSupport::Time' => 'ActiveSupport/TimeZones', + 'Rails::Application' => 'Rails/Application', + 'Rails::Engine' => 'Rails/Engine', + 'Rails::Generators' => 'Rails/Generators', + 'Rails::Railtie' => 'Rails/Railtie' } def get_type parent = at_css('.meta-parent').try(:content).to_s diff --git a/lib/docs/scrapers/rdoc/rails.rb b/lib/docs/scrapers/rdoc/rails.rb index 250f9b6c..e8b94149 100644 --- a/lib/docs/scrapers/rdoc/rails.rb +++ b/lib/docs/scrapers/rdoc/rails.rb @@ -13,54 +13,43 @@ module Docs options[:root_title] = 'Ruby on Rails' options[:skip] += %w( - AbstractController/Callbacks.html - AbstractController/UrlFor.html ActionController/Instrumentation.html ActionController/Rendering.html ActionDispatch/DebugExceptions.html - ActionDispatch/Http/URL.html ActionDispatch/Journey/Parser.html ActionDispatch/Reloader.html - ActionDispatch/RequestId.html ActionDispatch/Routing/HtmlTableFormatter.html - ActionDispatch/Routing/Mapper.html - ActionDispatch/Routing/RouteSet.html ActionDispatch/ShowExceptions.html - ActionView/FileSystemResolver.html ActionView/FixtureResolver.html ActionView/LogSubscriber.html - ActionView/Template/Handlers/Erubis.html ActionView/TestCase/Behavior/RenderedViewsCollection.html - ActiveRecord/DynamicMatchers/Finder.html - ActiveRecord/Sanitization.html ActiveRecord/Tasks/DatabaseTasks.html - ActiveSupport/Configurable/Configuration.html ActiveSupport/Dependencies/WatchStack.html - ActiveSupport/DescendantsTracker.html - ActiveSupport/FileUpdateChecker.html - ActiveSupport/Notifications/Fanout.html - ActiveSupport/Testing/Isolation/Subprocess.html - Rails/API/Task.html) + ActiveSupport/Notifications/Fanout.html) options[:skip_patterns] += [ - /\AActionController\/Caching(?!\/Fragments|\.)/, - /\AActionController\/RequestForgeryProtection\/ProtectionMethods/, /\AActionController\/Testing/, - /\AActionDispatch\/RemoteIp/, /\AActionView\/LookupContext/, /\AActionView\/Resolver/, /\AActiveSupport\/Multibyte\/Unicode\//, /\AActiveSupport\/XML/i, /\ASourceAnnotationExtractor/, /\AI18n\/Railtie/, + /\AMinitest/, + /\ARails\/API/, /\ARails\/AppBuilder/, - /\ARails\/PluginBuilder/] + /\ARails\/PluginBuilder/, + /\ARails\/Generators\/Testing/] options[:attribution] = <<-HTML © 2004–2016 David Heinemeier Hansson
Licensed under the MIT License. HTML + version '5.0' do + self.release = '5.0.0' + end + version '4.2' do self.release = '4.2.6' end