rusty-files
Rusty files is a simple collection of file functions that I use in my projects.
Instalation
Functons
delete_dir_contents - Recursively deletes all files and directories within a directory.
Arguments
dir_path- APathreference to the directory to delete the contents of.
use delete_dir_contents;
use Path;
check_if_path_exists - Checks if a file or directory exists at the given path.
Arguments
path- APathreference to the file or directory to check for existence.
Returns
A Result containing a bool indicating whether the file or directory exists (true) or not (false), or an std::io::Error if an I/O error occurred.
use check_if_path_exists;
use Path;