fn write_to_file(&self) -> anyhow::Result<()> {
        let content = toml::to_string(self)?;

        let path = self.get_settings_path()?;
        println!("Storing settings in {}", path.display());

        let mut file = File::create(path)?;
        file.write_all(content.as_bytes())?;

        Ok(())
    }
/// Convert `Settings` struct and write it out to a TOML file
Convert `Settings` struct and write it out to a TOML file
Convert ` Settings ` struct and write it out to a TOML file
fn write_to_file(&self) -> anyhow::Result<()> {
        let content = toml::to_string(self)?;
        let path = self.get_settings_path()?;
        println!("Storing settings in {}", path.display());
        let mut file = File::create(path)?;
        file.write_all(content.as_bytes())?;
        Ok(())
    }
fn write_to_file ( & self ) -> anyhow :: Result < ( ) > { let content = toml :: to_string ( self ) ? ; let path = self . get_settings_path ( ) ? ; println ! ( " " path display ( ) ) ; let mut file = File :: create ( path ) ? ; file . write_all ( content . as_bytes ( ) ) ? ; Ok ( ( ) ) }
Convert `Settings` struct and write it out to a TOML file
Convert ` Settings ` struct and write it out to a TOML file
&self
&self