This is a config file reader for Iron framework(an web framework writen in Rust).
You can put all you settings in a file which names Iron.toml.
1, The value of IRON_CONFIG_FILE in environment variable.
2, ./Iron.toml
3, ./site/Iron.toml
In you Cargo.toml:
toml
[dependencies]
iron_config = "0.1.0"
lazy_static = "*"
In you crate:
```rust extern crate ironconfig; use ironconfig::IC; #[macrouse] extern crate lazystatic; lazystatic!{ static ref DOMAIN: &'static str = IC.lookup("MAIN.DOMAIN").unwrap().asstr().unwrap(); }
fn main() {
println!("{:?}",*DOMAIN);
}
```
Apache License, Version 2.0, (LICENSE-APACHE or http://www.apache.org/licenses/LICENSE-2.0)
or
MIT License (LICENSE-MIT or http://opensource.org/licenses/MIT)