Functions§
- A wrapper around
std::fs::copy
which includes the file path in the panic message. - Copy a directory into another.
- A wrapper around
std::fs::create_dir
which includes the file path in the panic message. - A wrapper around
std::fs::create_dir_all
which includes the file path in the panic message. - A wrapper around
std::fs::File::create
which includes the file path in the panic message. - A wrapper around
std::fs::metadata
which includes the file path in the panic message. Note that this will traverse symlinks and will return metadata about the target file. Usesymlink_metadata
if you don’t want to traverse symlinks. - A wrapper around
std::fs::read
which includes the file path in the panic message. - A wrapper around
std::fs::read_dir
which includes the file path in the panic message. - Helper for reading entries in a given directory.
- A wrapper around
std::fs::read_to_string
which includes the file path in the panic message. - A wrapper around
std::fs::remove_dir
which includes the directory path in the panic message. - A wrapper around
std::fs::remove_dir_all
which includes the file path in the panic message. - A wrapper around
std::fs::remove_file
which includes the file path in the panic message. - A wrapper around
std::fs::rename
which includes the file path in the panic message. - A wrapper around
std::fs::set_permissions
which includes the file path in the panic message. - A function which prints all file names in the directory
dir
similarly to Unix’sls
. Useful for debugging. Usage:eprintln!("{:#?}", shallow_find_dir_entries(some_dir));
- Create a new symbolic link to a directory.
- Create a new symbolic link to a file.
- A wrapper around
std::fs::symlink_metadata
which includes the file path in the panic message. Note that this will not traverse symlinks and will return metadata about the filesystem entity itself. Usemetadata
if you want to traverse symlinks. - A wrapper around
std::fs::write
which includes the file path in the panic message.