2013-02-26 11:45:20 -05:00
## Rails 4.0.0 (unreleased) ##
2013-02-25 09:31:50 -05:00
## Rails 4.0.0.beta1 (February 25, 2013) ##
2013-03-01 13:09:34 -05:00
* Change Service pages(404, etc). *Stanislav Sobolev*
2013-02-24 13:46:27 -05:00
2013-01-24 15:19:51 -05:00
* Improve `rake stats` for JavaScript and CoffeeScript: ignore block comments
and calculates number of functions.
*Hendy Tanata*
2013-02-24 13:46:27 -05:00
* Ability to use a custom builder by passing `--builder` (or `-b` ) has been removed. Consider
using application template instead. See this guide for more detail:
http://guides.rubyonrails.org/rails_application_templates.html
*Prem Sichanugrist*
2013-02-20 09:02:00 -05:00
* fix rake db:* tasks to work with DATABASE_URL and without config/database.yml
*Terence Lee*
2012-01-02 15:49:18 -05:00
2013-02-07 18:53:11 -05:00
* Rails now generates a `test/test_helper.rb` file with `fixtures :all` commented out by default,
2013-02-06 01:03:17 -05:00
since we don't want to force loading all fixtures for user when a single test is run. However,
fixtures are still going to be loaded automatically for test suites.
To force all fixtures to be create in your database, use `rails test -f` to run your test.
*Prem Sichanugrist*
2013-02-07 18:53:11 -05:00
* Add `rails test` command for running tests
2013-01-25 13:44:36 -05:00
2013-02-07 18:53:11 -05:00
To run all tests:
2013-01-25 13:44:36 -05:00
$ rails test
2013-02-07 18:53:11 -05:00
To run a test suite
$ rails test [models,helpers,units,controllers,mailers,...]
To run a selected test file(s):
2013-01-25 13:44:36 -05:00
$ rails test test/unit/foo_test.rb [test/unit/bar_test.rb ...]
2013-02-07 18:53:11 -05:00
To run a single test from a test file
2013-01-25 13:44:36 -05:00
2013-02-07 18:53:11 -05:00
$ rails test test/unit/foo_test.rb -n test_the_truth
2013-01-25 13:44:36 -05:00
For more information, see `rails test --help` .
2013-02-07 18:53:11 -05:00
This command will eventually replace `rake test:*` and `rake test` tasks
2013-01-25 13:44:36 -05:00
*Prem Sichanugrist and Chris Toomey*
2013-02-11 08:24:38 -05:00
* Add notice message for destroy action in scaffold generator.
2013-02-09 12:10:45 -05:00
*Rahul P. Chaudhari*
2013-02-11 08:24:38 -05:00
* Add two new test rake tasks to speed up full test runs.
* `test:all` : run tests quickly by merging all types and not resetting db.
* `test:all:db` : run tests quickly, but also reset db.
*Ryan Davis*
* Add `--rc` option to support the load of a custom rc file during the generation of a new app.
2013-02-01 14:59:29 -05:00
*Amparo Luna*
2013-02-11 08:24:38 -05:00
* Add `--no-rc` option to skip the loading of railsrc file during the generation of a new app.
2013-01-31 19:30:47 -05:00
*Amparo Luna*
2012-11-23 15:30:15 -05:00
* Fixes database.yml when creating a new rails application with '.'
2013-03-09 13:04:57 -05:00
Fixes #8304 .
2012-11-23 15:30:15 -05:00
*Jeremy W. Rowe*
2012-12-19 01:54:09 -05:00
* Restore Rails::Engine::Railties#engines with deprecation to ensure
compatibility with gems such as Thinking Sphinx
2013-03-09 13:04:57 -05:00
Fixes #8551 .
2012-12-19 01:54:09 -05:00
*Tim Raymond*
2013-01-16 13:27:06 -05:00
* Specify which logs to clear when using the `rake log:clear` task.
(e.g. rake log:clear LOGS=test,staging)
*Matt Bridges*
2013-01-15 13:56:10 -05:00
* Allow a `:dirs` key in the `SourceAnnotationExtractor.enumerate` options
to explicitly set the directories to be traversed so it's easier to define
custom rake tasks.
*Brian D. Burns*
2013-01-12 07:52:13 -05:00
* Deprecate `Rails::Generators::ActiveModel#update_attributes` in favor of `#update` .
ORMs that implement `Generators::ActiveModel#update_attributes` should change
to `#update` . Scaffold controller generators should change calls like:
@orm_instance .update_attributes(...)
to:
@orm_instance .update(...)
This goes along with the addition of `ActiveRecord::Base#update` .
*Carlos Antonio da Silva*
2013-01-11 06:26:48 -05:00
* Include `jbuilder` by default and rely on its scaffold generator to show json API.
Check https://github.com/rails/jbuilder for more info and examples.
*DHH*
* Scaffold now generates HTML-only controller by default.
*DHH + Pavel Pravosud*
2013-01-07 18:50:12 -05:00
* The generated `README.rdoc` for new applications invites the user to
document the necessary steps to get the application up and running.
*Xavier Noria*
2013-01-07 18:16:19 -05:00
* Generated applications no longer get `doc/README_FOR_APP` . In consequence,
the `doc` directory is created on demand by documentation tasks rather than
generated by default.
*Xavier Noria*
2013-01-06 18:13:47 -05:00
* App executables now live in the `bin/` directory: `bin/bundle` ,
`bin/rails` , `bin/rake` . Run `rake rails:update:bin` to add these
executables to your own app. `script/rails` is gone from new apps.
Running executables within your app ensures they use your app's Ruby
version and its bundled gems, and it ensures your production deployment
tools only need to execute a single script. No more having to carefully
`cd` to the app dir and run `bundle exec ...` .
Rather than treating `bin/` as a junk drawer for generated "binstubs",
bundler 1.3 adds support for generating stubs for just the executables
you actually use: `bundle binstubs unicorn` generates `bin/unicorn` .
Add that executable to git and version it just like any other app code.
2013-01-06 23:53:30 -05:00
*Jeremy Kemper*
2013-01-05 16:13:10 -05:00
* `config.assets.enabled` is now true by default. If you're upgrading from a Rails 3.x app
2013-01-05 11:55:57 -05:00
that does not use the asset pipeline, you'll be required to add `config.assets.enabled = false`
2013-01-05 16:13:10 -05:00
to your application.rb. If you don't want the asset pipeline on a new app use `--skip-sprockets`
2013-01-05 11:55:57 -05:00
*DHH*
2013-01-04 19:36:49 -05:00
* Environment name can be a start substring of the default environment names
(production, development, test). For example: tes, pro, prod, dev, devel.
2013-03-09 13:04:57 -05:00
Fixes #8628 .
2013-01-02 05:41:35 -05:00
2013-01-04 19:36:49 -05:00
*Mykola Kyryk*
2013-01-02 05:41:35 -05:00
2013-01-04 19:36:49 -05:00
* Add `-B` alias for `--skip-bundle` option in the rails new generators.
2012-12-27 10:04:54 -05:00
2013-01-04 19:36:49 -05:00
*Jiri Pospisil*
2012-12-27 10:04:54 -05:00
2012-12-26 09:16:09 -05:00
* Quote column names in generates fixture files. This prevents
conflicts with reserved YAML keywords such as 'yes' and 'no'
2013-03-09 13:04:57 -05:00
Fixes #8612 .
2012-12-26 09:16:09 -05:00
*Yves Senn*
2012-12-23 21:56:43 -05:00
* Explicit options have precedence over `~/.railsrc` on the `rails new` command.
*Rafael Mendonça França*
2012-12-19 14:46:16 -05:00
* Generated migrations now always use the `change` method.
*Marc-André Lafortune*
2012-12-18 16:18:29 -05:00
* Add `app/models/concerns` and `app/controllers/concerns` to the default directory structure and load path.
2012-12-18 10:26:08 -05:00
See http://37signals.com/svn/posts/3372-put-chubby-models-on-a-diet-with-concerns for usage instructions.
2012-12-18 10:32:11 -05:00
2012-12-18 16:18:29 -05:00
*DHH*
2012-12-15 12:36:26 -05:00
* The `rails/info/routes` now correctly formats routing output as an html table.
*Richard Schneeman*
2012-12-18 10:26:08 -05:00
2012-12-14 17:16:59 -05:00
* The `public/index.html` is no longer generated for new projects.
Page is replaced by internal `welcome_controller` inside of railties.
Use Rails to Render Default Index Page
This is an alternative implementation to #7771 thanks to the advice of @spastorino
Rails is a dynamic framework that serves a static index.html by default. One of my first questions ever on IRC was solved by simply deleting my public/index.html file. This file is a source of confusion when starting as it over-rides any set "root" in the routes yet it itself is not listed in the routes. By making the page dynamic by default we can eliminate this confusion.
This PR moves the static index page to an internal controller/route/view similar to `rails/info`. When someone starts a rails server, if no root is defined, this route will take over and the "dynamic" index page from rails/welcome_controller will be rendered. These routes are only added in development. If a developer defines a root in their routes, it automatically takes precedence over this route and will be rendered, with no deleting of files required.
In addition to removing this source of confusion for new devs, we can now use Rails view helpers to build and render this page. While not the primary intent, the added value of "dogfooding" should not be under-estimated.
The prior PR #7771 had push-back since it introduced developer facing files. This PR solves all of the same problems, but does not have any new developer facing files (it actually removes one).
cc/ @wsouto, @dickeyxxx, @tyre, @ryanb, @josevalim, @maxim, @subdigital, @steveklabnik
ATP Railties and Actionpack.
2012-12-05 14:02:51 -05:00
*Richard Schneeman*
2012-12-14 17:16:59 -05:00
* Add `ENV['RACK_ENV']` support to `rails runner/console/server` .
2012-12-05 12:05:33 -05:00
*kennyj*
Use Rails to Render Default Index Page
This is an alternative implementation to #7771 thanks to the advice of @spastorino
Rails is a dynamic framework that serves a static index.html by default. One of my first questions ever on IRC was solved by simply deleting my public/index.html file. This file is a source of confusion when starting as it over-rides any set "root" in the routes yet it itself is not listed in the routes. By making the page dynamic by default we can eliminate this confusion.
This PR moves the static index page to an internal controller/route/view similar to `rails/info`. When someone starts a rails server, if no root is defined, this route will take over and the "dynamic" index page from rails/welcome_controller will be rendered. These routes are only added in development. If a developer defines a root in their routes, it automatically takes precedence over this route and will be rendered, with no deleting of files required.
In addition to removing this source of confusion for new devs, we can now use Rails view helpers to build and render this page. While not the primary intent, the added value of "dogfooding" should not be under-estimated.
The prior PR #7771 had push-back since it introduced developer facing files. This PR solves all of the same problems, but does not have any new developer facing files (it actually removes one).
cc/ @wsouto, @dickeyxxx, @tyre, @ryanb, @josevalim, @maxim, @subdigital, @steveklabnik
ATP Railties and Actionpack.
2012-12-05 14:02:51 -05:00
2012-12-01 15:23:39 -05:00
* Add `db` to list of folders included by `rake notes` and `rake notes:custom` . *Antonio Cangiano*
2012-11-18 11:57:55 -05:00
* Engines with a dummy app include the rake tasks of dependencies in the app namespace.
2013-03-09 13:04:57 -05:00
Fixes #8229 .
2012-11-18 11:57:55 -05:00
*Yves Senn*
2012-12-14 17:16:59 -05:00
* Add `sqlserver.yml` template file to satisfy `-d sqlserver` being passed to `rails new` .
2013-03-09 13:04:57 -05:00
Fixes #6882 .
2012-11-18 12:01:13 -05:00
2012-12-14 17:16:59 -05:00
*Robert Nesius*
2012-11-17 00:20:59 -05:00
2012-11-13 13:05:38 -05:00
* Rake test:uncommitted finds git directory in ancestors *Nicolas Despres*
2012-12-14 17:16:59 -05:00
* Add dummy app Rake tasks when `--skip-test-unit` and `--dummy-path` is passed to the plugin generator.
2013-03-09 13:04:57 -05:00
Fixes #8121 .
2012-11-07 14:54:49 -05:00
*Yves Senn*
2012-10-08 07:41:31 -04:00
* Add `.rake` to list of file extensions included by `rake notes` and `rake notes:custom` . *Brent J. Nordquist*
2012-10-08 00:59:42 -04:00
* New test locations `test/models` , `test/helpers` , `test/controllers` , and
`test/mailers` . Corresponding rake tasks added as well. *Mike Moore*
2012-11-07 14:54:49 -05:00
* Set a different cache per environment for assets pipeline
2012-10-09 13:16:51 -04:00
through `config.assets.cache` .
*Guillermo Iguaran*
2012-10-02 20:44:02 -04:00
* `Rails.public_path` now returns a Pathname object. *Prem Sichanugrist*
2012-09-09 00:18:57 -04:00
* Remove highly uncommon `config.assets.manifest` option for moving the manifest path.
2012-10-09 13:16:51 -04:00
This option is now unsupported in sprockets-rails.
2012-09-09 00:18:57 -04:00
*Guillermo Iguaran & Dmitry Vorotilin*
2012-09-19 18:10:32 -04:00
* Add `config.action_controller.permit_all_parameters` to disable
StrongParameters protection, it's false by default.
*Guillermo Iguaran*
2012-10-09 13:16:51 -04:00
* Remove `config.active_record.whitelist_attributes` and
2012-09-19 18:10:32 -04:00
`config.active_record.mass_assignment_sanitizer` from new applications since
MassAssignmentSecurity has been extracted from Rails.
*Guillermo Iguaran*
2012-09-12 21:15:38 -04:00
* Change `rails new` and `rails plugin new` generators to name the `.gitkeep` files
as `.keep` in a more SCM-agnostic way.
Change `--skip-git` option to only skip the `.gitignore` file and still generate
the `.keep` files.
Add `--skip-keeps` option to skip the `.keep` files.
*Derek Prior & Francesco Rodriguez*
2012-08-30 21:50:30 -04:00
* Fixed support for DATABASE_URL environment variable for rake db tasks. *Grace Liu*
2012-09-10 15:36:49 -04:00
* rails dbconsole now can use SSL for MySQL. The database.yml options sslca, sslcert, sslcapath, sslcipher,
and sslkey now affect rails dbconsole. *Jim Kingdon and Lars Petrus*
2012-08-10 17:27:51 -04:00
* Correctly handle SCRIPT_NAME when generating routes to engine in application
that's mounted at a sub-uri. With this behavior, you *should not* use
default_url_options[:script_name] to set proper application's mount point by
yourself. *Piotr Sarnacki*
2012-08-01 15:10:55 -04:00
* `config.threadsafe!` is deprecated in favor of `config.eager_load` which provides a more fine grained control on what is eager loaded *José Valim*
2012-07-08 09:01:49 -04:00
* The migration generator will now produce AddXXXToYYY/RemoveXXXFromYYY migrations with references statements, for instance
rails g migration AddReferencesToProducts user:references supplier:references{polymorphic}
will generate the migration with:
add_reference :products, :user, index: true
add_reference :products, :supplier, polymorphic: true, index: true
*Aleksey Magusev*
2012-06-27 12:06:47 -04:00
* Allow scaffold/model/migration generators to accept a `polymorphic` modifier
for `references` /`belongs_to`, for instance
rails g model Product supplier:references{polymorphic}
will generate the model with `belongs_to :supplier, polymorphic: true`
association and appropriate migration.
*Aleksey Magusev*
2012-06-10 05:38:37 -04:00
* Set `config.active_record.migration_error` to `:page_load` for development *Richard Schneeman*
2012-05-30 11:16:13 -04:00
* Add runner to Rails::Railtie as a hook called just after runner starts. *José Valim & kennyj*
2012-05-22 19:23:17 -04:00
* Add `/rails/info/routes` path, displays same information as `rake routes` *Richard Schneeman & Andrew White*
2012-05-19 09:18:37 -04:00
* Improved `rake routes` output for redirects *Łukasz Strzałkowski & Andrew White*
2012-05-16 18:40:57 -04:00
* Load all environments available in `config.paths["config/environments"]` . *Piotr Sarnacki*
2012-03-17 12:36:24 -04:00
* Remove Rack::SSL in favour of ActionDispatch::SSL. *Rafael Mendonça França*
2011-05-15 15:34:36 -04:00
* Remove Active Resource from Rails framework. *Prem Sichangrist*
2012-02-01 02:59:21 -05:00
* Allow to set class that will be used to run as a console, other than IRB, with `Rails.application.config.console=` . It's best to add it to `console` block. *Piotr Sarnacki*
Example:
# it can be added to config/application.rb
console do
# this block is called only when running console,
# so we can safely require pry here
require "pry"
config.console = Pry
end
2012-02-03 06:17:59 -05:00
* Add convenience `hide!` method to Rails generators to hide current generator
namespace from showing when running `rails generate` . *Carlos Antonio da Silva*
2012-01-02 15:49:18 -05:00
* Rails::Plugin has gone. Instead of adding plugins to vendor/plugins use gems or bundler with path or git dependencies. *Santiago Pastorino*
2012-06-23 15:21:33 -04:00
* Set config.action_mailer.async = true to turn on asynchronous
message delivery *Brian Cardarella*
2012-08-28 15:15:12 -04:00
Please check [3-2-stable ](https://github.com/rails/rails/blob/3-2-stable/railties/CHANGELOG.md ) for previous changes.