pub fn set_preference(key: &str, value: &str) -> Result<()>
Persist a key=value into the config file, preserving existing content.