1use clap::Parser;
4use voa_core::identifiers::{Context, Os, Purpose, Technology};
5
6use crate::{cli::OutputFormat, utils::RegularFile};
7
8#[derive(Debug, Parser)]
9pub struct VerifyCommand {
10 #[arg(env = "VOA_VERIFY_OS", help = "The OS to verify for.")]
11 pub os: Os,
12
13 #[arg(env = "VOA_VERIFY_PURPOSE", help = "The purpose to verify for.")]
14 pub purpose: Purpose,
15
16 #[arg(env = "VOA_VERIFY_CONTEXT", help = "The context to verify for.")]
17 pub context: Context,
18
19 #[arg(
20 env = "VOA_VERIFY_TECHNOLOGY",
21 help = "The technology to verify with.",
22 long_help = r#"The technology to verify with.
23
24Currently only "openpgp" is supported."#
25 )]
26 pub technology: Technology,
27
28 #[arg(env = "VOA_VERIFY_FILE", help = "The file to verify.")]
29 pub file: RegularFile,
30
31 #[arg(
32 env = "VOA_VERIFY_SIGNATURE",
33 help = "The signature to verify a file with."
34 )]
35 pub signatures: Vec<RegularFile>,
36
37 #[arg(
38 env = "VOA_VERIFY_OUTPUT_FORMAT",
39 help = "The output format to use.",
40 long,
41 short,
42 default_value_t = OutputFormat::default()
43 )]
44 pub output_format: OutputFormat,
45}