| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
| |
|
|
|
|
| |
only if config.ru is not present in current dir
|
| |
|
|
|
|
|
|
|
|
| |
After that commit, developers can set ENGINE_PATH in ENGINE/scripts/rails
file and load application's ./script/rails (most of the time it will be
dummy application used for testing). When running ./script/rails g it will
use application to boot up, but then it will use Engine's root and
configuration for generators.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
from railties.
With config.generators becomes a way to configure generators
for current instance only. For example:
module Blog
class Engine < Rails::Engine
config.generators do |g|
g.orm :active_record
end
config.app_generators do |g|
g.test_framework :rspec
end
end
end
such definition sets :active_record as orm for engine and :rspec
as test_framework for application. The values set with app_generators
can be overwritten in application using config.generators as you would
normally do:
module MyApp
class Application < Rails::Application
config.generators do |g|
g.test_framework :test_unit
end
end
end
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Sometimes it's easier to define routes inside Engine or
Application class definition (e.g. one file applications). The
problem with such case is that if there is a plugin that
has config/routes.rb file, it will trigger routes reload on application.
Since routes definition for application is not in config/routes.rb
file routes_reloader will fail to reload application's routes
properly. With this commit you can pass routes definition as a block
to routes method, which will allow to properly reload it:
class MyApp::Application < Rails::Application
routes do
resources :users
end
end
|
|
|
|
|
|
|
|
|
| |
or application.
In order to run Engine as standalone application, you will need
Rails::Application instance in the same namespace that engine
one. It's very important to leave _railtie bound to whatever
used "namespace" method first.
|
|\ |
|
| |
| |
| |
| |
| |
| |
| |
| | |
Removed non-functional links.
Removed links to API documentation.
Removed link to Rails 2 material.
Renamed "References" to "Further Reading".
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
These plugins are obsolete even for Rails 2, they have no place in a Rails 3 guide.
Also removed "mad cool" reference.
If anyone has ideas about cache plugins that *must* be included, I would love to know.
As far as I am concerned the rails guides should stick to built-in methods and have a
simple list of references for people wishing to investigate further.
I will check out the references after this commit to see if they're up to date.
|
| | |
|
| | |
|
| | |
|
| |
| |
| |
| | |
module.
|
| |
| |
| |
| | |
throwing 404s.
|
| | |
|
| |\ |
|
| | | |
|
| |/
| |
| |
| | |
Example code fixes in Layouts and Rendering guide.
|
| | |
|
| |
| |
| |
| |
| |
| | |
ActiveRecord::Base.find.
Added `where` as a method to has_many and has_and_belongs_to_many collections.
|
| |
| |
| |
| |
| |
| | |
Rails with Arel edge
[#5723 state:committed]
|
| | |
|
| |
| |
| |
| |
| |
| | |
This removes all deprecated classes in ActionController related to
Routing, Abstract Request/Response and Integration/IntegrationTest.
All tests and docs were changed to ActionDispatch instead of ActionController.
|
| |
| |
| |
| |
| |
| |
| | |
Normally Rails.application is an instance, but for those
tests Rails.application needs to be class.
Signed-off-by: José Valim <jose.valim@gmail.com>
|
| |
| |
| |
| |
| |
| | |
Rails::Generators::NamedBase
Signed-off-by: José Valim <jose.valim@gmail.com>
|
| |
| |
| |
| | |
Signed-off-by: José Valim <jose.valim@gmail.com>
|
| |
| |
| |
| | |
Signed-off-by: José Valim <jose.valim@gmail.com>
|
| |
| |
| |
| | |
Signed-off-by: José Valim <jose.valim@gmail.com>
|
| | |
|
| |
| |
| |
| |
| |
| | |
purpose of different behavior in tests and in application
Signed-off-by: José Valim <jose.valim@gmail.com>
|
| |
| |
| |
| |
| |
| | |
namespaced model
Signed-off-by: José Valim <jose.valim@gmail.com>
|
| |
| |
| |
| |
| |
| | |
warnings in the scaffold_generator tests [#4872 state:resolved]
Signed-off-by: Santiago Pastorino <santiago@wyeworks.com>
|
| | |
|
| |
| |
| |
| | |
Signed-off-by: José Valim <jose.valim@gmail.com>
|
| |
| |
| |
| | |
Signed-off-by: José Valim <jose.valim@gmail.com>
|
| |
| |
| |
| | |
Signed-off-by: José Valim <jose.valim@gmail.com>
|
| |
| |
| |
| |
| |
| | |
state:resolved]
Signed-off-by: José Valim <jose.valim@gmail.com>
|
|/
|
|
| |
Signed-off-by: José Valim <jose.valim@gmail.com>
|
|\ |
|
| | |
|
| | |
|
| |
| |
| |
| |
| | |
config.action_controller.use_accept_header.
See http://github.com/rails/rails/blob/v3.0.0/actionpack/lib/action_controller/deprecated/base.rb#L108-111
|
| |
| |
| |
| | |
store table
|
| |
| |
| |
| | |
ActiveSupport::TestCase
|
| | |
|
| | |
|
| | |
|