confiture

Crates.ioconfiture
lib.rsconfiture
version0.1.4
sourcesrc
created_at2022-04-20 20:17:20.885926
updated_at2022-04-20 20:35:38.258404
descriptionA really simple create to manage config from toml file
homepage
repository
max_upload_size
id571175
size3,358
Théo Daron (Kaporos)

documentation

README

Confiture

Confiture is a really simple crate to manage config from toml file.

Usage

#[derive(Serialize, Deserialize, Debug, Default)]
#[serde(default)]
struct Config {
    title: String,
}

fn main() {
     let mut cfg = Config::from_toml_file("config.toml").unwrap();
     cfg.title = String::from("Jean");
     cfg.save_to_file("config.toml").unwrap();
}
Commit count: 0

cargo fmt