class Initializer

Ruby on Rails 2.3.18

Since v2.2.3 Last seen in v2.3.18

Available in: v2.2.3 v2.3.18

The Initializer is responsible for processing the Rails configuration, such as setting the $LOAD_PATH, requiring the right frameworks, initializing logging, and more. It can be run either as a single command that’ll just use the default configuration, like this:

Rails::Initializer.run

But normally it’s more interesting to pass in a custom configuration through the block running:

Rails::Initializer.run do |config|
  config.frameworks -= [ :action_mailer ]
end

This will use the default configuration options from Rails::Configuration, but allow for overwriting on select areas.

Inherits from

Object

Attributes

Methods (defined here)

Methods (inherited)

From Object (37)
From Benchmark (2)

Type at least 2 characters to search.

↑↓ navigate · open · esc close