webterm_agent/
args.rs

1use clap::Parser;
2
3#[derive(Parser, Debug)]
4#[command(version, about = "Learn more at https://github.com/nasa42/webterm", long_about = None)]
5pub struct Args {
6    /// Device Name, must be at least 16 characters long
7    #[arg(long, env = "WT_DEVICE_NAME")]
8    pub device_name: String,
9
10    #[arg(long, env = "WT_SECRET_KEY")]
11    pub secret_key: String,
12
13    /// Relays to use, comma separated. If blank, default relays are used.
14    /// If present, none of the default relays would be used.
15    /// E.g., --relays relay1.example.com,relay2.example.com
16    #[arg(long, env = "WT_RELAYS")]
17    pub relays: Option<String>,
18
19    #[arg(long, env = "WT_DEVICE_SUBNAME")]
20    pub device_subname: Option<String>,
21
22    #[arg(long, env = "WT_DAEMON", short = 'd')]
23    pub daemon: bool,
24}