Crate file_operation

Source
Expand description

file-operation

A Rust library providing comprehensive utilities for file operations with both sync/async support. Includes operations for copy, delete, move, read and write files. Simplifies file handling in Rust projects with safe and efficient methods for file manipulation and metadata querying.

Structs§

FileDataString
A wrapper struct for file data in string format.

Functions§

append_to_file
Appends content to a file.
async_append_to_file
Appends content to a file asynchronously.
async_copy_dir_files
Asynchronously copies all files from the source directory to the destination directory.
async_copy_file
Asynchronously copies a file from the source path to the destination path.
async_delete_dir
Asynchronously deletes a directory and all its contents.
async_delete_file
Asynchronously deletes a file at the given path.
async_get_file_size
Gets the size of a file in bytes.
async_move_dir
Moves a directory and all its contents to another location asynchronously.
async_move_file
Moves a file from the source path to the destination path asynchronously.
async_read_from_file
Reads the content of a file and converts it to the specified type.
async_write_to_file
Writes content to a file asynchronously.
copy_dir_files
Copies all files from the source directory to the destination directory.
copy_file
Copies a file from the source path to the destination path.
delete_dir
Deletes a directory and all its contents.
delete_file
Deletes a file at the given path.
get_file_size
Gets the size of a file in bytes.
move_dir
Moves a directory and all its contents to another location.
move_file
Moves a file from the source path to the destination path.
read_from_file
Reads the content of a file and converts it to the specified type.
write_to_file
Writes content to a file.