Skip to main content

write_text

Function write_text 

Source
pub fn write_text(path: &Path, contents: &str) -> Result<()>
Expand description

Replace a UTF-8 text file’s contents directly.

§Errors

Returns a contextual error when the contents cannot be written.