1 2 3 4 5 6 7 8 9 10 11
use std::path::Path; /// Returns true if the path is a file pub fn is_file(path: &str) -> bool { Path::new(path).is_file() } /// Returns true if the path is a directory pub fn is_dir(path: &str) -> bool { Path::new(path).is_dir() }