Download
49 lines 1.4 KiBRustModified 2026-10-16 raw
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849
mod backup;
mod commands;
mod config;
mod drives;
mod format;
mod state;
mod wipe;

use state::AppState;
use std::sync::Mutex;

fn main() {
    tauri::Builder::default()
        .manage(Mutex::new(AppState::new()))
        .invoke_handler(tauri::generate_handler![
            commands::list_drives,
            commands::open_drive,
            commands::unlock_drive,
            commands::get_config,
            commands::save_config,
            commands::update_config,
            commands::add_job,
            commands::delete_job,
            commands::eject,
            commands::unmount_device,
            commands::preview_commands,
            commands::start_backup,
            commands::get_backup_progress,
            commands::pause_backup,
            commands::resume_backup,
            commands::cancel_backup,
            commands::start_probe_drive,
            commands::get_drive_probe,
            commands::format_command_preview,
            commands::start_format,
            commands::get_format_progress,
            commands::get_status,
            commands::list_snapshots,
            commands::preview_restore,
            commands::start_restore,
            commands::start_wipe_free_space,
            commands::get_wipe_progress,
            commands::cancel_wipe,
            commands::list_dir,
            commands::quit,
        ])
        .run(tauri::generate_context!())
        .expect("error while running tauri application");
}