fix: rename args variables

This commit is contained in:
2025-11-14 13:45:40 +01:00
parent 36bc38a5a2
commit d94ed4d167
2 changed files with 4 additions and 4 deletions

2
Cargo.lock generated
View File

@@ -54,7 +54,7 @@ dependencies = [
[[package]]
name = "bak"
version = "0.2.0"
version = "0.3.2"
dependencies = [
"clap",
"sha2",

View File

@@ -4,8 +4,8 @@ use std::path::PathBuf;
use std::process;
#[derive(Parser)]
#[command(version, about, long_about = None)]
struct Opts {
#[command(name = "bak-rs", version, about, long_about = None)]
struct Args {
/// Optional subcommand (restore or delete). Default is backup
#[command(subcommand)]
command: Option<Commands>,
@@ -21,7 +21,7 @@ enum Commands {
}
fn main() {
let opts = Opts::parse();
let opts = Args::parse();
let result = match opts.command {
Some(Commands::Res { file }) => restore_backup_file(&file),