Skip to content

Override configuration using environment variables #541

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 5 commits into from
Jan 13, 2018

Conversation

Michael-F-Bryan
Copy link
Contributor

@Michael-F-Bryan Michael-F-Bryan commented Jan 13, 2018

This lets you override config options by setting the appropriate environment variables. This is essentially just a wrapper around the Config::set() method, with the original "index" being provided by the environment variable's key (after a couple transforms).

closes #540, closes #291.

@Michael-F-Bryan
Copy link
Contributor Author

Looks like travis are still having issues with their mac builds, all 4 mac jobs are still "waiting to be queued". I think it should still be safe to merge this PR though.

@Michael-F-Bryan Michael-F-Bryan merged commit a1b6ccc into rust-lang:master Jan 13, 2018
@Michael-F-Bryan Michael-F-Bryan deleted the env-config branch January 26, 2018 03:17
Ruin0x11 pushed a commit to Ruin0x11/mdBook that referenced this pull request Aug 30, 2020
* Added the ability to update config settings from env vars

* Added tests

* Documented that you can override configuration with environment
variables

* Refactored the config get() methods to use toml-query

* Made the `Updateable` trait more generic
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

If SUMMARY.md doesn't contain a file, mdbook doesn't give an error
1 participant