summaryrefslogtreecommitdiffstats
path: root/examples/simple/src/main.rs
diff options
context:
space:
mode:
authorRyan Leckey <leckey.ryan@gmail.com>2017-07-30 13:20:36 -0700
committerRyan Leckey <leckey.ryan@gmail.com>2017-07-30 13:20:36 -0700
commit14224be23dc2f253a240b85214927d97e1160669 (patch)
tree6f5b02b26aef5cf37bb14f32b9048165b67109ce /examples/simple/src/main.rs
parent71f4b182d1e56febda64bd620ae0e0f65de333cd (diff)
Remove ConfigResult; close #36
Diffstat (limited to 'examples/simple/src/main.rs')
-rw-r--r--examples/simple/src/main.rs8
1 files changed, 4 insertions, 4 deletions
diff --git a/examples/simple/src/main.rs b/examples/simple/src/main.rs
index debad02..fb66e03 100644
--- a/examples/simple/src/main.rs
+++ b/examples/simple/src/main.rs
@@ -3,13 +3,13 @@ extern crate config;
use std::collections::HashMap;
fn main() {
- let settings = config::Config::default()
+ let mut settings = config::Config::default();
+ settings
// Add in `./Settings.toml`
- .merge(config::File::with_name("Settings"))
+ .merge(config::File::with_name("Settings")).unwrap()
// Add in settings from the environment (with a prefix of APP)
// Eg.. `APP_DEBUG=1 ./target/app` would set the `debug` key
- .merge(config::Environment::with_prefix("APP"))
- .unwrap();
+ .merge(config::Environment::with_prefix("APP")).unwrap();
// Print out our settings (as a HashMap)
println!("{:?}",