bw/platform/
mod.rs

1use clap::{Args, Subcommand};
2
3use crate::render::CommandResult;
4
5#[derive(Args, Clone)]
6pub struct SyncArgs {
7    #[arg(short = 'f', long, help = "Force a full sync.")]
8    pub force: bool,
9
10    #[arg(long, help = "Get the last sync date.")]
11    pub last: bool,
12}
13
14#[derive(Subcommand, Clone)]
15pub enum ConfigCommand {
16    Server {
17        base_url: Option<String>,
18
19        #[arg(
20            long,
21            help = "Provides a custom web vault URL that differs from the base URL."
22        )]
23        web_vault: Option<String>,
24
25        #[arg(
26            long,
27            help = "Provides a custom API URL that differs from the base URL."
28        )]
29        api: Option<String>,
30        #[arg(
31            long,
32            help = "Provides a custom identity URL that differs from the base URL."
33        )]
34        identity: Option<String>,
35        #[arg(
36            long,
37            help = "Provides a custom icons service URL that differs from the base URL."
38        )]
39        icons: Option<String>,
40        #[arg(
41            long,
42            help = "Provides a custom notifications URL that differs from the base URL."
43        )]
44        notifications: Option<String>,
45        #[arg(
46            long,
47            help = "Provides a custom events URL that differs from the base URL."
48        )]
49        events: Option<String>,
50
51        #[arg(long, help = "Provides the URL for your Key Connector server.")]
52        key_connector: Option<String>,
53    },
54}
55
56impl ConfigCommand {
57    #[allow(clippy::unused_async)]
58    pub async fn run(self) -> CommandResult {
59        todo!()
60    }
61}