Commit Graph

166 Commits

Author SHA1 Message Date
Abhay Nikam
1a03cd4913
[ci skip] Documents the --skip-docker rails command line argument (#46823) 2022-12-25 22:04:38 +05:30
Jonathan Hefner
a4dbfc0089 Use yaml code fence [ci-skip]
This changes a `bash` code fence with `cat` output to a `yaml` code
fence for proper YAML syntax highlighting.  This also fixes a typo in
the YAML content.
2022-11-15 13:57:15 -06:00
Missy Davies
d49a3abc01 Capitalize headings to match style guidelines
Fix all headings to follow Rails Guides Guidelines
2022-10-17 17:01:28 -10:00
Jonathan Hefner
9ac01c6a81 Use relative URLs for intra-guide links [ci-skip]
This ensures that the URLs are properly versioned when the guides are
rendered.
2022-08-05 21:36:18 -05:00
Emmanuel Hayford
d2050b2adc Use suggested version of note [ci-skip]
my_app seems to be what Rails docs use mostly. Changed it for some
consistency
2022-06-16 01:36:35 +02:00
Petrik
e5a06ecefe Update Command Line guide --database usage [ci-skip]
The current Command Line guide has an advanced section describing
specifying git as SCM and PostgreSQL as the database. This section is
easily overlooked: https://github.com/rails/rails/issues/44325

By moving whole "advanced" section under the `rails new` section, it's
easier to find. Also specifying the database is pretty common I guess
and not an "advanced" topic.

All mentions of the SCM option have been removed, as it seems to no
longer be an option and we always initialize with Git only.
2022-06-14 22:18:31 +02:00
Emmanuel Hayford
a3ffa9b908 Add info and fix command description [ci-skip] 2022-06-13 21:11:17 +02:00
Wilfried OLLIVIER
0f2a97f6ca Move rails new doc into a new header 2022-06-04 17:08:51 +02:00
Jonathan Hefner
73e0a9c749 Clarify scaffold generator explanation [ci-skip] 2022-02-13 13:07:51 -06:00
Ghouse Mohamed
680df32812 Added more skip options for rails command line documentation 2022-02-12 22:46:56 +05:30
Ghouse Mohamed
97bf34fdd5 Improve Rails 7 documentation for the command line and asset pipeline 2022-02-12 10:31:13 +05:30
Rafael Mendonça França
83d85b2207
Start Rails 7.1 development 2021-12-07 15:52:30 +00:00
Rafael Mendonça França
4ace047c91
Add back Rack::Runtime to the default middleware stack.
We were planning to remove this middleware because we thought it could
make easier to attacker to do a Time Attack. However, while
Rack::Runtime can indeed be used to know how long a request took, and
compare with other requests, it doesn't provide any information that
can't be found in the total time of the request as well.

Instead of removing the middleware, we decided to keep it, and direct
users to instead of removing it, use its information to uncover actions
that are vulnerable to Time Attack.

This reverts commit 127dd06df66552dd272eea7832f8bb205cf6fd01, reversing
changes made to 4354e3ae492e95934a6da4101556a05d20b9f897.
2021-09-15 18:37:34 -04:00
David Heinemeier Hansson
d5b9618da1
Remove default reliance on Sass and CSS generators (#43110)
* No benefit to having actiontext css as scss

* Update test

* Update docs

* No more css assets to be generated

New world, new CSS frameworks, new needs.

* SCSS is becoming optional

* Remove Sass as a default-on setting

But continue to make it easy to add.

* Update docs

* No longer used

* Update tests

* Update docs

* Update docs

* No longer used

* No longer by default

* Fix tests

* Promote Tailwind CSS as an alternative to Sass

* Fix test and copy task

* Update railties/lib/rails/generators/rails/app/templates/Gemfile.tt

Co-authored-by: Kevin Newton <kddnewton@gmail.com>

Co-authored-by: Kevin Newton <kddnewton@gmail.com>
2021-08-26 13:40:25 +02:00
David Heinemeier Hansson
21c9732fae
Remove spring as a default installation option (#42997)
* Remove spring as a default installation option

Faster computers have meant that most apps won't see a big benefit from Spring on small to moderate size apps. Thus the pain of dealing with the occasional spring issue is no longer warranted by default.

* Errant end

* No longer an option

* Additional spring removals

* Pointer to docs is enough
2021-08-12 12:31:18 +02:00
Marc Anguera
51cebff059
Remove docs of now gone --skip-gemfile [skip ci]
Related to #42996.
Similar to 8d1b8e870c
2021-08-11 17:37:15 +02:00
David Heinemeier Hansson
8d1b8e870c Remove test and docs of now gone --skip-puma 2021-08-11 16:35:15 +02:00
David Heinemeier Hansson
e34300a921
Stop trying to configure listen by default on compatible platforms (#42985)
* Stop trying to configure listen by default on compatible platforms

Modern computers with SSDs don't see much/any benefit from having an evented file update watcher. Remove complexity by taking this spinning-drive concession out.

* Actually need listen for testing the opt-in

* Test no longer relevant
2021-08-11 15:18:43 +02:00
Aditya Pandit
72b62f392e Matched guide example with rails api docs [ci skip] 2021-05-01 13:18:45 +05:30
aphel
011180e56c
Document input format for multiple arguments 2021-04-15 05:47:03 +01:00
Hartley McGuire
7bfcf4b313 Remove Rack::Runtime and deprecate referencing it
Previous discussion: #38412, #38325, 37423e4, 24f9c03

- Rack::Runtime is replaced by FakeRuntime, which is a dummy middleware
  that just passes requests on and cannot be used in middleware operations
- Using Rack::Runtime in middleware operations (relative inserts, moves,
  etc.) throws a deprecation warning and uses FakeRuntime instead
- if an application adds Rack::Runtime explicitly (use, unshift, etc.),
  then the deprecation warning does not happen and FakeRuntime is
  ignored
- docs are updated to no longer reference Rack::Runtime
2021-04-12 14:31:12 -04:00
Rafael Mendonça França
6487836af8
Rails 7 requires Ruby 2.7 and prefer Ruby 3+
The code cleanup is comming in later commits but this
already remove support to Ruby < 2.7.
2021-02-04 16:34:53 +00:00
Jonathan Hefner
3c9d7a268f Use irb code fences where applicable [ci-skip]
Using `irb` code fences and the appropriate prompt syntax results in
better syntax highlighting.
2020-11-01 16:29:18 -06:00
Eileen M. Uchitelle
9a36b50b84
Merge branch 'master' into combine-structure-and-schema-tasks 2020-08-17 08:47:51 -04:00
Abhay Nikam
d747b53172 Document the --database/--db option for multiple database Rails application [skip ci] 2020-08-11 21:37:37 +05:30
fatkodima
5488686851 Combine and deprecate rails db:structure:{dump,load} tasks into rails db:schema:{dump,load} 2020-08-03 19:08:41 +03:00
Jonathan Hefner
481035fba0 Use bash code fences and prompts for shell code [ci skip]
Follow-up to #39594, which added CSS in order to select shell commands
sans prompts on triple-click.

This commit adds several bash code fences and prompts where they were
missing, and removes a few where they were inappropriate.
2020-06-13 19:27:30 -05:00
Petrik
2b09948637 Replace 'Stubs out' with 'Generates' in generator USAGE's [ci skip]
Generators generate things, but what is meant by 'Stubbing out' might
confuse beginners and non-native English speakers.
While generated tests are stubs that should have an implementation, a
generated model is a valid model that doesn't require any changes.
2020-06-03 08:51:47 +02:00
Haroon Ahmed
6504e97561 update global rails commands to bundled rails i.e. bin/rails 2020-04-11 17:32:26 +01:00
Haroon Ahmed
db1ae8cbb4 remove reference to global rails command and replace with bin/rails 2019-12-27 19:32:37 +00:00
mikong
40372c59de
Update rails server terminal output in Guides [ci skip] 2019-10-19 12:57:13 +08:00
Takayuki Nakata
83037c0bcf Fix a document to update postgresql version for rails6 [ci skip]
In rails6, versions 9.3 and up are supported.
2019-08-28 10:06:21 +09:00
Sharang Dashputre
18504eb78f Use a single term instead of all terms used to describe path and URL helpers together 2019-07-26 23:54:39 +05:30
OKURA Masafumi
7250c0ae4e Add some commands to misc section in CLI guide
Add these two command:

* `rails initializers`
* `rails middleware`
2019-06-20 18:49:50 +09:00
Younes SERRAJ
0e77abaaf6 List available skip options in command line guide [ci skip] 2019-05-15 11:15:49 +02:00
Alec Clarke
9aad9ae26f [ci skip] Update the guide's model generator output.
The model generator code sample used in the command line guides
was displaying an outdated output for the generator's usage.
This change updates the sample to mirror what's currently output
when running `$rails generate model`.
2019-04-27 10:32:48 -04:00
soartec-lab
cdbb224a50 Update the generate command sample codes [skip ci] 2019-04-17 00:10:41 +09:00
Younes SERRAJ
6463cc0573 Adds register_tags 2019-04-12 08:55:42 +02:00
Sharang Dashputre
771973c13d url -> URL where apt except inside actionpack/ 2019-04-01 22:56:35 +05:30
Sergio
3c7ab1a45a
Spelling error 2019-03-26 02:04:04 -06:00
Nathaniel Suchy
d9f1cc05b5 Update links and code examples in the guides to use HTTPS where the host supports it. 2019-03-06 15:21:07 -05:00
Alberto Almagro
41e47f5155 Indent guides as rails help command output[ci skip]
The output from `rails help` actually leaves an empty space when
printing the command lists. This commit adapts this guide to have the
same format.
2018-11-19 22:48:50 +01:00
Prathamesh Sonpatki
e8546aba90 Update the docs now that webpacker is default [ci skip] 2018-10-03 00:03:16 +05:30
Xavier Noria
f589e20b0a use "minitest" consistently
The name of the minitest library is spelled that way: regular font, and
lowercase. Lowercase is used even at the beginning of sentences, see

    http://docs.seattlerb.org/minitest/

I double-checked this with @zenspider too (thanks!).
2018-09-11 23:57:25 +02:00
Matthew Draper
ec387c6dd9
Merge pull request #33229 from albertoalmagro/albertoalmagro/prefer-rails-command-over-bin-rails
Prefer rails command over bin/rails
2018-07-25 04:10:29 +09:30
Paul McMahon
7b9c19d94b Rails guides are now served over https
http links will be redirected to the https version, but still better to
just directly link to the https version.
2018-07-24 11:29:31 +09:00
Alberto Almagro
6567464bed Homogenize rails commands and former rake tasks
This commit integrates most used previously rake commands into the
above outer list. Ordering is based on their individual predicted
frequency of use.

Separation between bin/rails tasks is also removed to display all
commands at the same level.

It also removes references to rake and tasks and substitutes them
for command.
2018-07-06 22:46:53 +02:00
Alberto Almagro
40b209db53 Recommend use of rails over bin/rails
As discussed in #33203 rails command already looks for, and runs,
bin/rails if it is present.

We were mixing recommendations within guides and USAGE guidelines,
in some files we recommended using rails, in others bin/rails and
in some cases we even had both options mixed together.
2018-07-06 22:46:35 +02:00
Kasper Timm Hansen
ba38e13c82
Merge pull request #33220 from anniecodes/notes-command
Adds `Rails::Command::NotesCommand` and makes `rake notes` use it under the hood
2018-07-05 10:32:58 +02:00
Annie-Claude Côté
1edc7263c8 [ci skip] Update documentation related to rails notes
* Get rid of references to rake notes in the documentation
* Get rid of references to environement variables used in SourceAnnotationExtractor
* Updates the command line guide to reflect the new rails notes API
2018-07-03 21:27:22 -04:00