From 2d003ef00c6e0b5dc7969865b85db823e1227c27 Mon Sep 17 00:00:00 2001 From: Steve Polito Date: Fri, 6 Oct 2023 19:45:04 -0400 Subject: [PATCH] Introduce `railsrc` Introduces [railsrc][1] in an effort to prepare for the eventual [removal of the suspenders executable][2]. With this change, calling `rails new` will automatically set the following options: ``` --database=postgresql ``` If you need to use another database, you can override this value like so: `rails new my_app --database=mysql` or `rails new my_app --no_rc` to skip this file all together [1]: https://github.com/rails/rails/blob/7f7f9df8641e35a076fe26bd097f6a1b22cb4e2d/railties/lib/rails/generators/rails/app/USAGE#L5C1-L7 [2]: https://github.com/thoughtbot/suspenders/blob/main/GOALS.md#from-here-to-there --- README.md | 8 ++++++++ railsrc | 1 + 2 files changed, 9 insertions(+) create mode 100644 railsrc diff --git a/README.md b/README.md index e700e5c5f8..4bcf8dc0a4 100644 --- a/README.md +++ b/README.md @@ -214,6 +214,14 @@ configuration: - Add trusted binstubs to the `PATH`. - Load the ASDF version manager. +[Rails](https://rubyonrails.org) + +- Adds [railsrc][] with `--database=postgresql`. If you need to use another + database, you can override this value like so: `rails new my_app --database=mysql` or +`rails new my_app --no_rc` + +[railsrc]: https://github.com/rails/rails/blob/7f7f9df8641e35a076fe26bd097f6a1b22cb4e2d/railties/lib/rails/generators/rails/app/USAGE#L5C1-L7 + Shell aliases and scripts: - `b` for `bundle`. diff --git a/railsrc b/railsrc new file mode 100644 index 0000000000..9a34b2e6dd --- /dev/null +++ b/railsrc @@ -0,0 +1 @@ +--database=postgresql