Add file_name argument
This commit is contained in:
parent
f41c061109
commit
44a83fe03b
@ -42,12 +42,15 @@ enum Command {
|
|||||||
/// How to handle older versions of the file
|
/// How to handle older versions of the file
|
||||||
#[arg(short = 'a', long, default_value = "delete", default_missing_value = "archive", num_args = 0..1)]
|
#[arg(short = 'a', long, default_value = "delete", default_missing_value = "archive", num_args = 0..1)]
|
||||||
old_version_policy: OldVersionPolicy,
|
old_version_policy: OldVersionPolicy,
|
||||||
/// The directory where to upload to
|
/// The directory where to upload to, relative to the server directory
|
||||||
#[arg(short = 'p', long, default_value = "plugins")]
|
#[arg(short = 'p', long, default_value = "plugins")]
|
||||||
upload_directory: PathBuf,
|
upload_directory: PathBuf,
|
||||||
/// Skip the confirmation dialog
|
/// Skip the confirmation dialog
|
||||||
#[arg(long, default_value = "false", default_missing_value = "true", num_args = 0..1)]
|
#[arg(long, default_value = "false", default_missing_value = "true", num_args = 0..1)]
|
||||||
no_confirm: bool,
|
no_confirm: bool,
|
||||||
|
/// The prefix of the name of older versions of the file, which should be replaced or deleted
|
||||||
|
#[arg(short, long)]
|
||||||
|
file_name: Option<String>,
|
||||||
},
|
},
|
||||||
/// Execute a command on the servers
|
/// Execute a command on the servers
|
||||||
#[command(visible_short_flag_alias = 'c')]
|
#[command(visible_short_flag_alias = 'c')]
|
||||||
@ -95,6 +98,7 @@ fn main() -> Result<(), String> {
|
|||||||
old_version_policy,
|
old_version_policy,
|
||||||
upload_directory,
|
upload_directory,
|
||||||
no_confirm,
|
no_confirm,
|
||||||
|
file_name,
|
||||||
} => {
|
} => {
|
||||||
todo!()
|
todo!()
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user