Skip to content

Commit 7745f71

Browse files
committed
Fixed Railtie Rdoc examples not properly formatted [#4918 state:resolved]
Signed-off-by: Simone Carletti <weppos@weppos.net>
1 parent b3bb684 commit 7745f71

File tree

1 file changed

+21
-21
lines changed

1 file changed

+21
-21
lines changed

railties/lib/rails/railtie.rb

Lines changed: 21 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -6,53 +6,53 @@
66
module Rails
77
# Railtie is the core of the Rails Framework and provides several hooks to extend
88
# Rails and/or modify the initialization process.
9-
#
9+
#
1010
# Every major component of Rails (Action Mailer, Action Controller,
1111
# Action View, Active Record and Active Resource) are all Railties, so each of
1212
# them is responsible to set their own initialization. This makes, for example,
1313
# Rails absent of any Active Record hook, allowing any other ORM framework to hook in.
14-
#
14+
#
1515
# Developing a Rails extension does _not_ require any implementation of
1616
# Railtie, but if you need to interact with the Rails framework during
1717
# or after boot, then Railtie is what you need to do that interaction.
18-
#
18+
#
1919
# For example, the following would need you to implement Railtie in your
2020
# plugin:
21-
#
21+
#
2222
# * creating initializers
2323
# * configuring a Rails framework or the Application, like setting a generator
2424
# * adding Rails config.* keys to the environment
2525
# * setting up a subscriber to the Rails +ActiveSupport::Notifications+
2626
# * adding rake tasks into rails
27-
#
27+
#
2828
# == Creating your Railtie
2929
#
3030
# Implementing Railtie in your Rails extension is done by creating a class
3131
# Railtie that has your extension name and making sure that this gets loaded
3232
# during boot time of the Rails stack.
33-
#
33+
#
3434
# You can do this however you wish, but here is an example if you want to provide
3535
# it for a gem that can be used with or without Rails:
36-
#
36+
#
3737
# * Create a file (say, lib/my_gem/railtie.rb) which contains class Railtie inheriting from
3838
# Rails::Railtie and is namespaced to your gem:
3939
#
40-
# # lib/my_gem/railtie.rb
41-
# module MyGem
42-
# class Railtie < Rails::Railtie
40+
# # lib/my_gem/railtie.rb
41+
# module MyGem
42+
# class Railtie < Rails::Railtie
43+
# end
4344
# end
44-
# end
45-
#
45+
#
4646
# * Require your own gem as well as rails in this file:
47-
#
48-
# # lib/my_gem/railtie.rb
49-
# require 'my_gem'
50-
# require 'rails'
51-
#
52-
# module MyGem
53-
# class Railtie < Rails::Railtie
47+
#
48+
# # lib/my_gem/railtie.rb
49+
# require 'my_gem'
50+
# require 'rails'
51+
#
52+
# module MyGem
53+
# class Railtie < Rails::Railtie
54+
# end
5455
# end
55-
# end
5656
#
5757
# == Initializers
5858
#
@@ -65,7 +65,7 @@ module Rails
6565
# end
6666
# end
6767
#
68-
# If specified, the block can also receive the application object, in case you
68+
# If specified, the block can also receive the application object, in case you
6969
# need to access some application specific configuration, like middleware:
7070
#
7171
# class MyRailtie < Rails::Railtie

0 commit comments

Comments
 (0)