aboutsummaryrefslogtreecommitdiffstats
path: root/guides
diff options
context:
space:
mode:
authorAaron Patterson <aaron.patterson@gmail.com>2014-04-09 11:03:10 -0700
committerAaron Patterson <aaron.patterson@gmail.com>2014-04-09 11:03:10 -0700
commitdb5e578b647e1730ea2aecb1ca58fd9a434f6cf6 (patch)
tree524517ae1ffc1ec01af367d72a51a8323dee931b /guides
parent3321d1a2d1908f25d962169d0a88b55bca3c2370 (diff)
parent7b75b678cf11a1aed7927a9db42fb60a38726450 (diff)
downloadrails-db5e578b647e1730ea2aecb1ca58fd9a434f6cf6.tar.gz
rails-db5e578b647e1730ea2aecb1ca58fd9a434f6cf6.tar.bz2
rails-db5e578b647e1730ea2aecb1ca58fd9a434f6cf6.zip
Merge branch 'master' into adequaterecord
* master: (26 commits) Avoid URI parsing Add missing require so requiring `active_support/cache` works again. depend_on_asset is not required anymore on sprockets-rails 2.1.2 upgrading section for 4.1 is no longer WIP. [ci skip] Expand explanation of how to set secrets.yml. [ci skip] Guides: minor typo fixed [ci skip] Fixed problem where `1.day.eql?(1.day)` is false new CHANGELOGs entries are in the top [ci skip] Updates the maintenance policy with new Rails versions Dont abbreviate that which needs no abbreviation Dont encourage aliases now that we have variants Use short-form for the scaffold render calls and drop the needless test Drop in @jeremy's new database.yml template text Don't deprecate after all Less ambition, more deprecation Ensure we correctly and immediately load all ENV entries Give a deprecation message even when the lookup fails Rearrange the config merger some more entry is always a Hash Check env_url only once ... Conflicts: Gemfile
Diffstat (limited to 'guides')
-rw-r--r--guides/CHANGELOG.md4
-rw-r--r--guides/source/asset_pipeline.md25
-rw-r--r--guides/source/maintenance_policy.md6
-rw-r--r--guides/source/upgrading_ruby_on_rails.md13
4 files changed, 19 insertions, 29 deletions
diff --git a/guides/CHANGELOG.md b/guides/CHANGELOG.md
index 246e1d3b96..14ad4fd424 100644
--- a/guides/CHANGELOG.md
+++ b/guides/CHANGELOG.md
@@ -1,3 +1,7 @@
+* Updates the maintenance policy to match the latest versions of Rails
+
+ *Matias Korhonen*
+
* Switched the order of `Applying a default scope` and `Merging of scopes` subsections so default scopes are introduced first.
*Alex Riabov*
diff --git a/guides/source/asset_pipeline.md b/guides/source/asset_pipeline.md
index 5bb895cb78..9338f570a7 100644
--- a/guides/source/asset_pipeline.md
+++ b/guides/source/asset_pipeline.md
@@ -245,7 +245,7 @@ When a file is referenced from a manifest or a helper, Sprockets searches the
three default asset locations for it.
The default locations are: the `images`, `javascripts` and `stylesheets`
-directories under the `apps/assets` folder, but these subdirectories
+directories under the `app/assets` folder, but these subdirectories
are not special - any path under `assets/*` will be searched.
For example, these files:
@@ -581,23 +581,8 @@ runtime. To disable this behavior you can set:
config.assets.raise_runtime_errors = false
```
-When `raise_runtime_errors` is set to `false` sprockets will not check that dependencies of assets are declared properly. Here is a scenario where you must tell the asset pipeline about a dependency:
-
-If you have `application.css.erb` that references `logo.png` like this:
-
-```css
-#logo { background: url(<%= asset_data_uri 'logo.png' %>) }
-```
-
-Then you must declare that `logo.png` is a dependency of `application.css.erb`, so when the image gets re-compiled, the css file does as well. You can do this using the `//= depend_on_asset` declaration:
-
-```css
-//= depend_on_asset "logo.png"
-#logo { background: url(<%= asset_data_uri 'logo.png' %>) }
-```
-
-Without this declaration you may experience strange behavior when pushing to production that is difficult to debug. When you have `raise_runtime_errors` set to `true`, dependencies will be checked at runtime so you can ensure that all dependencies are met.
-
+When this option is true asset pipeline will check if all the assets loaded in your application
+are included in the `config.assets.precompile` list.
### Turning Debugging Off
@@ -943,7 +928,7 @@ gem.
```ruby
config.assets.css_compressor = :yui
```
-The other option for compressing CSS if you have the sass-rails gem installed is
+The other option for compressing CSS if you have the sass-rails gem installed is
```ruby
config.assets.css_compressor = :sass
@@ -1018,7 +1003,7 @@ The X-Sendfile header is a directive to the web server to ignore the response
from the application, and instead serve a specified file from disk. This option
is off by default, but can be enabled if your server supports it. When enabled,
this passes responsibility for serving the file to the web server, which is
-faster. Have a look at [send_file](http://api.rubyonrails.org/classes/ActionController/DataStreaming.html#method-i-send_file)
+faster. Have a look at [send_file](http://api.rubyonrails.org/classes/ActionController/DataStreaming.html#method-i-send_file)
on how to use this feature.
Apache and nginx support this option, which can be enabled in
diff --git a/guides/source/maintenance_policy.md b/guides/source/maintenance_policy.md
index 93729c6f72..8f119f36aa 100644
--- a/guides/source/maintenance_policy.md
+++ b/guides/source/maintenance_policy.md
@@ -20,7 +20,7 @@ Only the latest release series will receive bug fixes. When enough bugs are
fixed and its deemed worthy to release a new gem, this is the branch it happens
from.
-**Currently included series:** 4.0.z
+**Currently included series:** 4.1.z, 4.0.z
Security Issues
---------------
@@ -35,7 +35,7 @@ be built from 1.2.2, and then added to the end of 1-2-stable. This means that
security releases are easy to upgrade to if you're running the latest version
of Rails.
-**Currently included series:** 4.0.z, 3.2.z
+**Currently included series:** 4.1.z, 4.0.z
Severe Security Issues
----------------------
@@ -44,7 +44,7 @@ For severe security issues we will provide new versions as above, and also the
last major release series will receive patches and new versions. The
classification of the security issue is judged by the core team.
-**Currently included series:** 4.0.z, 3.2.z
+**Currently included series:** 4.1.z, 4.0.z, 3.2.z
Unsupported Release Series
--------------------------
diff --git a/guides/source/upgrading_ruby_on_rails.md b/guides/source/upgrading_ruby_on_rails.md
index 88c9981dbb..9fbe3313d2 100644
--- a/guides/source/upgrading_ruby_on_rails.md
+++ b/guides/source/upgrading_ruby_on_rails.md
@@ -25,8 +25,6 @@ TIP: Ruby 1.8.7 p248 and p249 have marshaling bugs that crash Rails. Ruby Enterp
Upgrading from Rails 4.0 to Rails 4.1
-------------------------------------
-NOTE: This section is a work in progress.
-
### CSRF protection from remote `<script>` tags
Or, "whaaat my tests are failing!!!?"
@@ -79,12 +77,15 @@ secrets, you need to:
secret_key_base:
production:
- secret_key_base:
+ secret_key_base: <%= ENV["SECRET_KEY_BASE"] %>
```
-2. Copy the existing `secret_key_base` from the `secret_token.rb` initializer to
- `secrets.yml` under the `production` section.
-
+2. Use your existing `secret_key_base` from the `secret_token.rb` initializer to
+ set the SECRET_KEY_BASE environment variable for whichever users run the Rails
+ app in production mode. Alternately, you can simply copy the existing
+ `secret_key_base` from the `secret_token.rb` initializer to `secrets.yml`
+ under the `production` section, replacing '<%= ENV["SECRET_KEY_BASE"] %>'.
+
3. Remove the `secret_token.rb` initializer.
4. Use `rake secret` to generate new keys for the `development` and `test` sections.