Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Merge branch 'master' of git://github.com/lifo/docrails

  • Loading branch information...
commit 89d825d02172f7c1ba1211119ea9844206aae9c3 2 parents 5e7ce47 + 6ce844a
Xavier Noria fxn authored
5 actionmailer/lib/rails/generators/mailer/USAGE
View
@@ -1,4 +1,5 @@
Description:
+============
Stubs out a new mailer and its views. Pass the mailer name, either
CamelCased or under_scored, and an optional list of emails as arguments.
@@ -6,10 +7,12 @@ Description:
engine and test framework generators.
Example:
- `rails generate mailer Notifications signup forgot_password invoice`
+========
+ rails generate mailer Notifications signup forgot_password invoice
creates a Notifications mailer class, views, test, and fixtures:
Mailer: app/mailers/notifications.rb
Views: app/views/notifications/signup.erb [...]
Test: test/functional/notifications_test.rb
Fixtures: test/fixtures/notifications/signup [...]
+
2  activesupport/lib/active_support/backtrace_cleaner.rb
View
@@ -8,7 +8,7 @@ module ActiveSupport
# filter or modify the paths of any lines of the backtrace, you can call BacktraceCleaner#remove_filters! These two methods
# will give you a completely untouched backtrace.
#
- # Example:
+ # ==== Example:
#
# bc = BacktraceCleaner.new
# bc.add_filter { |line| line.gsub(Rails.root, '') }
12 activesupport/lib/active_support/configurable.rb
View
@@ -64,21 +64,21 @@ def #{name}=(value); config.#{name} = value; end
end
# Reads and writes attributes from a configuration <tt>OrderedHash</tt>.
- #
- # require 'active_support/configurable'
- #
+ #
+ # require 'active_support/configurable'
+ #
# class User
# include ActiveSupport::Configurable
- # end
+ # end
#
# user = User.new
- #
+ #
# user.config.allowed_access = true
# user.config.level = 1
#
# user.config.allowed_access # => true
# user.config.level # => 1
- #
+ #
def config
@_config ||= self.class.config.inheritable_copy
end
11 activesupport/lib/active_support/core_ext/hash/reverse_merge.rb
View
@@ -3,12 +3,23 @@ class Hash
#
# options = options.reverse_merge(:size => 25, :velocity => 10)
#
+<<<<<<< HEAD
+ # The default <tt>:size</tt> and <tt>:velocity</tt> are only set if the +options+ hash passed in doesn't already
+ # have the respective key.
+ #
+ # As contrast, using Ruby's built in <tt>merge</tt> would require writing the following:
+ #
+ # def setup(options = {})
+ # options = { :size => 25, :velocity => 10 }.merge(options)
+ # end
+=======
# is equivalent to
#
# options = {:size => 25, :velocity => 10}.merge(options)
#
# This is particularly useful for initializing an options hash
# with default values.
+>>>>>>> 20768176292cbcb883ab152b4aa9ed8c664771cd
Aaron Patterson Owner

Ruh roh. Mergefail.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
def reverse_merge(other_hash)
other_hash.merge(self)
end
4 activesupport/lib/active_support/core_ext/object/blank.rb
View
@@ -13,7 +13,11 @@ def blank?
respond_to?(:empty?) ? empty? : !self
end
+<<<<<<< HEAD
+ # An object is present if it's not #blank?.
+=======
# An object is present if it's not <tt>blank?</tt>.
+>>>>>>> 20768176292cbcb883ab152b4aa9ed8c664771cd
def present?
!blank?
end
4 activesupport/lib/active_support/hash_with_indifferent_access.rb
View
@@ -1,7 +1,7 @@
require 'active_support/core_ext/hash/keys'
# This class has dubious semantics and we only have it so that
-# people can write params[:key] instead of params['key']
+# people can write <tt>params[:key]</tt> instead of <tt>params['key']</tt>
# and they get the same value for both keys.
module ActiveSupport
@@ -109,7 +109,7 @@ def merge(hash)
end
# Performs the opposite of merge, with the keys and values from the first hash taking precedence over the second.
- # This overloaded definition prevents returning a regular hash, if reverse_merge is called on a HashWithDifferentAccess.
+ # This overloaded definition prevents returning a regular hash, if reverse_merge is called on a <tt>HashWithDifferentAccess</tt>.
def reverse_merge(other_hash)
super self.class.new_from_hash_copying_default(other_hash)
end
2  activesupport/lib/active_support/i18n_railtie.rb
View
@@ -14,7 +14,7 @@ def self.reloader
@reloader ||= ActiveSupport::FileUpdateChecker.new([]){ I18n.reload! }
end
- # Add I18n::Railtie.reloader to ActionDispatch callbacks. Since, at this
+ # Add <tt>I18n::Railtie.reloader</tt> to ActionDispatch callbacks. Since, at this
# point, no path was added to the reloader, I18n.reload! is not triggered
# on to_prepare callbacks. This will only happen on the config.after_initialize
# callback below.
2  activesupport/lib/active_support/log_subscriber.rb
View
@@ -21,7 +21,7 @@ module ActiveSupport
# ActiveRecord::LogSubscriber.attach_to :active_record
#
# Since we need to know all instance methods before attaching the log subscriber,
- # the line above should be called after your ActiveRecord::LogSubscriber definition.
+ # the line above should be called after your <tt>ActiveRecord::LogSubscriber</tt> definition.
#
# After configured, whenever a "sql.active_record" notification is published,
# it will properly dispatch the event (ActiveSupport::Notifications::Event) to
2  activesupport/lib/active_support/message_encryptor.rb
View
@@ -7,7 +7,7 @@ module ActiveSupport
#
# The cipher text and initialization vector are base64 encoded and returned to you.
#
- # This can be used in situations similar to the MessageVerifier, but where you don't
+ # This can be used in situations similar to the <tt>MessageVerifier</tt>, but where you don't
# want users to be able to determine the value of the payload.
class MessageEncryptor
class InvalidMessage < StandardError; end
2  activesupport/lib/active_support/message_verifier.rb
View
@@ -2,7 +2,7 @@
require 'active_support/core_ext/object/blank'
module ActiveSupport
- # MessageVerifier makes it easy to generate and verify messages which are signed
+ # +MessageVerifier+ makes it easy to generate and verify messages which are signed
# to prevent tampering.
#
# This is useful for cases like remember-me tokens and auto-unsubscribe links where the
2  railties/guides/source/active_record_querying.textile
View
@@ -420,7 +420,7 @@ Client.limit(5).offset(30)
will return instead a maximum of 5 clients beginning with the 31st. The SQL looks like:
<sql>
-SELECT * FROM clients LIMIT 5, 30
+SELECT * FROM clients LIMIT 5 OFFSET 30
</sql>
h3. Group
14 railties/guides/source/contributing_to_ruby_on_rails.textile
@@ -364,6 +364,20 @@ Please make sure the patch does not introduce whitespace errors:
$ git apply --whitespace=error-all mynew_patch.diff
</shell>
+You can check your patches by applying your patch to an different dedicated branch:
+
+<shell>
+$ git checkout -b testing_branch
+$ git apply --check my_new_patch.diff
+</shell>
+
+You can make sure your patches don't add any whitespace by applying it yourself using the --whitespace=error-all option. Make sure you are on your dedicated test branche and:
+
+<shell>
+$ git apply --whitespace=error-all mynew_patch.diff
+</shell>
+
+
h4. Create a Lighthouse Ticket
Now create a ticket with your patch. Go to the "new ticket":http://rails.lighthouseapp.com/projects/8994-ruby-on-rails/tickets/new page at Lighthouse. Fill in a reasonable title and description, remember to attach your patch file, and tag the ticket with the ‘patch’ tag and whatever other subject area tags make sense.

2 comments on commit 89d825d

Ben Orenstein

Looks like there were some merge conflicts.

Xavier Noria
Owner

Oh shit, git didn't tell. Gonna fix them. Thanks for the heads up!

Please sign in to comment.
Something went wrong with that request. Please try again.