| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
| |
Without this, `dbconsole` raises an error as follwing:
```
RuntimeError: can't modify frozen String
railties/lib/rails/commands/dbconsole/dbconsole_command.rb:79:in `start'
```
|
| |
|
| |
|
|
|
|
|
|
|
| |
Since #29725, load application file when `dbconsole` command is executed.
However, if do not set `RAILS_ENV` before reading the application file,
can not connect to the env specified in option, so added the setting
of `RAILS_ENV`.
|
|
|
|
|
|
|
|
|
| |
Running the `console` and `dbconsole` commands with a regular argument
as the environment's name automatically expand it to match an existing
environment (e.g. dev for development).
This feature wasn't available using the `--environment` (a.k.a `-e`)
option.
|
|
|
|
|
|
|
|
|
|
|
| |
Since 0a4f6009, it's possible to specify a 3-level database
configuration to gather connections by environment.
The `dbconsole` command will try to look for a database configuration
which points to the current environment but with such flavour, the
environment key is flushed out so let's add the ability to specify
the connection and pick `primary` by default to be consistent with
Active Record.
|
|
|
|
|
|
|
|
|
| |
Currently the environment file is not loaded in `dbconsole` command.
Therefore, for example, if use encrypted secrets values in database.yml,
`read_encrypted_secrets` will not be true, so the value can not be
used correctly.
Fixes #29717
|
| |
|
|
|
|
|
| |
The `header` option checks only whether it is specified or not.
https://github.com/rails/rails/blob/e8c33349bfabca28996ac74d344d69c7aaffec50/railties/lib/rails/commands/dbconsole/dbconsole_command.rb#L52
|
| |
|
|
|
|
| |
YAML and ERB were removed at 971d510
|
|
|
|
|
| |
They're just barren on the site and confure more than guide, instead
rely on the built in --help to guide users.
|
| |
|
|
|