memea::db

Function write_db

Source
pub fn write_db(
    db: &Database,
    filename: &PathBuf,
    verbose: bool,
) -> Result<(), MemeaError>
Expand description

Writes a database to file with overwrite confirmation if the file exists.

§Arguments

  • db - Database to write
  • filename - Target file path
  • verbose - Whether to show verbose output

§Returns

  • Ok(()) - Database was successfully written
  • Err(MemeaError) - File operation failed or user canceled