Commit Graph

5507 Commits

Author SHA1 Message Date
Eileen M. Uchitelle
bd53f35e25
Merge pull request #32818 from mechanicles/remove-sentence-confusion
Remove confusion in the sentence [ci skip]
2018-05-04 07:58:47 -04:00
Santosh Wadghule
8831155f64
Remove confusion in the sentence [ci skip] 2018-05-04 17:19:35 +05:30
Tyler Hunt
3fbd60a008
Minor edits to the Active Storage guide
Fix spelling, grammar, and formatting.

[ci skip]
2018-05-03 11:20:51 -04:00
Ryuta Kamizono
11549e815a Partly revert "Use https with weblog URI" [ci skip]
weblog.jamisbuck.org is not GitHub Pages.
2018-05-03 18:32:03 +09:00
Yoshiyuki Hirano
f3c71ff1e1 Use https with weblog URI 2018-05-02 21:06:03 +09:00
George Claghorn
ee6a431bb9
Merge pull request #32769 from anthonycrumley/document-active-storage-folder
Document rails new <app> storage folder
2018-04-30 17:40:57 -04:00
Anthony Crumley
6b6996c5e5 Document rails new <app> storage folder
[ci skip] Active Storage now adds a storage folder to newly generated
rails applications.
2018-04-30 16:33:55 -05:00
Anthony Crumley
7549f830a2 Fix an oxford comma
[ci skip]
2018-04-30 16:13:39 -05:00
Jonathan Roes
5a7fadf684
Remove reference to Tokaido 2018-04-30 10:28:01 -04:00
Chris Houhoulis
e7ba10b9a9 Fix url_helper examples in testing guide [ci skip] 2018-04-29 20:19:22 -04:00
Ryuta Kamizono
cc5f077f09 We usually do not use GH#1234 style in the CHANGELOGs [ci skip] 2018-04-29 16:54:19 +09:00
George Claghorn
3e8c660c11
Merge pull request #32698 from zealot128/patch-1
[ci skip] update ActiveStorage documentation
2018-04-28 14:10:59 -05:00
Stefan Wienert
4212470d20
[ci skip] update ActiveStorage documentation
- added documentation on how to download files, with example of
  ActiveStorage::Downloading
- documentation about linking files outside of controller/view
- added section about DirectUpload JavaScript integration into
  libraries/frameworks, as well as usage in combination with Drag and Drop
2018-04-28 20:48:13 +02:00
Pradyumna Shembekar
678a1af2e3
[ci skip] Fix typo in testing.md 2018-04-27 23:00:56 -07:00
simonjamain
1230253153 Adding precision about which letter case to use for controller names … (#32740)
* Adding precision about which letter case to use for controller names in routing

Many people (including myself) encounter an error when having multiple words controller names and trying to put camelCase in their routes
2018-04-27 14:09:54 -04:00
Jamie Dihiansan
46b46e85c7 Update 'rails_welcome.png' to reflect a more diverse population (#32735)
* Update 'rails_welcome.png' to reflect a more diverse population

* Cleanup 'rails_welcome.png'
2018-04-26 14:30:35 -07:00
Rafael França
03721d9379
Merge pull request #32702 from bogdanvlviv/fix-description-for-31685
Fix title for example of removing data from `session` [ci skip]
2018-04-25 02:31:58 -04:00
Daniel Colson
cc6d2dc0de Fix typo in migrations guide [ci skip]
Introduced in #32646
2018-04-24 12:54:33 -04:00
Sean Griffin
42c9b560cb
Merge pull request #32646 from derekprior/dp-schema-dumper-documentation
Update schema.rb documentation [CI SKIP]
2018-04-24 10:31:46 -06:00
Derek Prior
84718df860
Update schema.rb documentation [CI SKIP]
The documentation previously claimed that `db/schema.rb` was "the
authoritative source for your database schema" while simultaneously
also acknowledging that the file is generated. These two statements are
incongruous and the guides accurately call out that many database
constructs are unsupported by `schema.rb`. This change updates the
comment at the top of `schema.rb` to remove the assertion that the file
is authoritative.

The documentation also previously referred vaguely to "issues" when
re-running old migrations. This has been updated slightly to hint at the
types of problems that one can encounter with old migrations.

In sum, this change attempts to more accurately capture the pros, cons,
and shortcomings of the two schema formats in the guides and in the
comment at the top of `schema.rb`.

[Derek Prior & Sean Griffin]
Co-authored-by: Sean Griffin <sean@seantheprogrammer.com>
2018-04-24 11:18:11 -04:00
George Claghorn
ef5902a2f1
Merge pull request #32471 from janko-m/use-image_processing-gem
Use ImageProcessing gem for ActiveStorage variants
2018-04-23 16:01:16 -05:00
Janko Marohnić
7e4ad3f13d
Correct typos 2018-04-23 21:06:06 +02:00
Janko Marohnić
eef0bd0c0a
Recommend using :resize_to_fit after all 2018-04-23 21:04:35 +02:00
bogdanvlviv
d2fd01ec68
Fix title for example of removing data from session [ci skip]
After #31685 the description says different what
we expect to see in the example. Change `assign that key to be nil` to
`or delete the key/value pair` in order to highlight what is shown in the example.

Fix one more example of removing data from the session in favour of using
`delete` since assigning to `nil` doesn't delete key from it.
2018-04-23 21:59:39 +03:00
Rafael Barbolo
80cbf19453 Remove key from session by using session.delete (#31685)
* Remove key from session by using session.delete

You are not deleting a key from session when you assign nil to that key.

* Update guides on how to destroy a user session

In this commit, the user id is removed from session and controller's variables related to the user are nullified.

[Rafael Mendonça França + Rafael Barbolo]
2018-04-23 13:50:59 -04:00
Janko Marohnić
dc97f6c3fd
Replace :resize_to_fit with :resize in the guide 2018-04-23 12:35:43 +02:00
Janko Marohnić
f01e249890
Rename ActiveStorage.processor to .variant_processor 2018-04-22 23:40:42 +02:00
Guillermo Iguaran
76acaf6eb9
Merge pull request #32689 from yhirano55/update-testing-guides
Update results of command in Testing guides [ci skip]
2018-04-22 15:58:27 -05:00
Yoshiyuki Hirano
b261508002 Refactor guides javascripts
* Remove `$` prefix from all variables (`$` prefix means jQuery object)
* Old browsers doesn't support forEach. So use for instead of forEach.
2018-04-23 04:30:47 +09:00
Yoshiyuki Hirano
915efecc1b Update results of command in Testing guides [ci skip]
* Results of command in testing guides are different from actual ones.
* Updated them.
2018-04-23 03:26:31 +09:00
Yoshiyuki Hirano
419adbf1a5 ✂️ jQuery for Rails Guides
* Rewrite with Vanilla JS
* Confirmed with Chrome, Safari, Firefox
2018-04-21 20:59:45 +09:00
Rafael França
1e56b31dd6
Merge pull request #32572 from nao0515ki/add_optional_true_to_self_joins_section
[ci skip] belongs_to in self join association needs optional: true, if it's over 5.0 ver of rails
2018-04-20 16:30:06 -04:00
Rafael França
b8cd9302fe
Merge pull request #32575 from ybakos/guides/testing/pluralize_class_names
guides/testing: Pluralize controller and helper class names.
2018-04-19 23:57:43 -04:00
Rafael França
3812ef8b66
Merge pull request #32574 from DmytroVasin/rails-ujs-stoppable-events
Rails-ujs: Info about stoppable events
2018-04-19 23:37:01 -04:00
Rafael França
8bdf50d515
Merge pull request #32401 from yhirano55/improve_css_in_guide
Improve css in guide
2018-04-19 15:37:31 -04:00
Stephen
50182f67e7 [ci skip] Fix minor system testing documentation typo. 2018-04-18 16:49:20 -04:00
Andrew White
185fce1597
Merge pull request #32607 from yaroslav/feature/nonce-for-javascript_include_tag
Add the `nonce: true` option for `javascript_include_tag` helper.
2018-04-18 18:49:27 +01:00
Janko Marohnić
ca12968587
Use ImageProcessing gem for ActiveStorage variants
ImageProcessing gem is a wrapper around MiniMagick and ruby-vips, and
implements an interface for common image resizing and processing. This
is the canonical image processing gem recommended in [Shrine], and
that's where it developed from. The initial implementation was extracted
from Refile, which also implements on-the-fly transformations.

Some features that ImageProcessing gem adds on top of MiniMagick:

  * resizing macros
    - #resize_to_limit
    - #resize_to_fit
    - #resize_to_fill
    - #resize_and_pad
  * automatic orientation
  * automatic thumbnail sharpening
  * avoids the complex and inefficient MiniMagick::Image class
  * will use "magick" instead of "convert" on ImageMagick 7

However, the biggest feature of the ImageProcessing gem is that it has
an alternative implementation that uses libvips. Libvips is an
alternative to ImageMagick that can process images very rapidly (we've
seen up 10x faster than ImageMagick).

What's great is that the ImageProcessing gem provides the same interface
for both implementations. The macros are named the same, and the libvips
implementation does auto orientation and thumbnail sharpening as well;
only the operations/options specific to ImageMagick/libvips differ. The
integration provided by this PR should work for both implementations.

The plan is to introduce the ImageProcessing backend in Rails 6.0 as the
default backend and deprecate the MiniMagick backend, then in Rails 6.1
remove the MiniMagick backend.
2018-04-18 17:46:25 +02:00
Yaroslav Markin
47013a7126 Add the nonce: true option for javascript_include_tag helper. 2018-04-17 22:50:33 +03:00
Paul
319248c049
Correct docs on naming of sprockets manifest file
Calling this an MD5 implies that it is generated consistently based on some input.
However, this value is [completely random](fbe6e450b6/lib/sprockets/manifest_utils.rb (L11-L24)).
2018-04-17 12:29:24 -07:00
Rafael França
5003d5996a
Merge pull request #32582 from cassidycodes/better-examples
Inclusive Language in Documentation Examples
2018-04-16 23:07:43 -04:00
Cassidy Kobewka
3137a8739e
Use string-based fields. [ci skip] 2018-04-16 19:09:45 -04:00
Ryuta Kamizono
75210560f1
Merge pull request #32596 from bogdanvlviv/add-reference-to-5_2-from-edge-guides
Add the reference to Rails Guides 5.2 from the Edge Guides
2018-04-17 07:20:34 +09:00
bogdanvlviv
659d16c895
Add the reference to Rails Guides 5.2 from the Edge Guides
[ci skip]
2018-04-17 00:15:37 +03:00
Jolyon Pawlyn
ffa558efcf Update Rails minor version from 5.1 to 5.2 [ci skip] 2018-04-16 22:33:02 +02:00
Cassidy Kobewka
2aa8e0a56f
Inclusive Language in Documentation Examples [ci skip] 2018-04-15 12:34:30 -04:00
Yong Bakos
91a5821175 guides/testing: Pluralize controller and helper class names.
The Rails convention for controllers and helpers is plural, except where
intentionally singular. Pluralize the controller and helper class names,
to match convention.
2018-04-14 10:31:58 -07:00
Dmytro Vasin
e3fcd96dc4 Fix stoppable events in tests and docs. 2018-04-14 19:44:14 +03:00
nao0515ki
8300268441 [ci skip] belongs_to in self join association needs optional: true, if it's over 5.0 ver of rails 2018-04-14 22:28:01 +09:00
szTheory
fe1c93aa1d
Update security.md with latest underground market prices
Updated underground market prices according to the 2017 Symantec ISTR (was previously citing the 2008 report)
2018-04-13 10:34:37 -04:00