Skip to content

Commit

Permalink
feat(config): add docs for rc configs
Browse files Browse the repository at this point in the history
  • Loading branch information
wzrdtales committed Nov 30, 2016
1 parent 00f5726 commit 774cf2b
Showing 1 changed file with 30 additions and 3 deletions.
33 changes: 30 additions & 3 deletions Getting Started/configuration.md
Original file line number Diff line number Diff line change
Expand Up @@ -87,11 +87,38 @@ In addition, the default env can also be set with an environment variable. This
}
```

Alternatively, you can specify a DATABASE_URL
environment variable that will be used in place of the configuration
file settings. This is helpful for use with Heroku.
## DATABASE_URL

Alternatively, you can specify a `DATABASE_URL` environment variable that will
be used in place of the configuration file settings. This is helpful for use
with Heroku.

**Note**: If a database url is specified, the config file is being skipped. You
can however also specify rc configs, where you can configure everything you can
configure also on the CLI.

## RC configs

RC configs give the possibility to configure settings for more than just one
project, as RC configs are being loaded from different directories.

You can take a view over [here](https://github.com/dominictarr/rc#standards)
where to save those configs.

Most prominent locations are, the root directory where you currently execute
db-migrate and your `HOME` directory. The file is always named .db-migraterc,
except for some examples you can find under the link above.

An example .db-migraterc config file could look like this:

```json
{
"sql-file": true
}
```

This would set activate the sql mode unless you would deactivate it in your
database.json again, which always has the highest priority.

## Important - For MySQL users

Expand Down

1 comment on commit 774cf2b

@ivarconr
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

Please sign in to comment.