temp_dir

Function temp_dir 

Source
pub fn temp_dir() -> Result<PlatformPathBuf>
Expand description

Returns the path of a temporary directory as PlatformPathBuf.

§Errors

Returns an Err if unable to parse the path with the platform encoding.

§Examples

fn main() -> std::io::Result<()> {
    let path = typed_path::utils::temp_dir()?;
    println!("The temporary directory path is {}", path.display());
    Ok(())
}