diff options
author | fxqnlr <[email protected]> | 2024-09-09 23:03:49 +0200 |
---|---|---|
committer | fxqnlr <[email protected]> | 2024-09-09 23:03:49 +0200 |
commit | 553bbac36bdc483135a7053ca64507e01397e5e1 (patch) | |
tree | 494dad0623628df4f1b86b93da51edf60795a901 /src/cli.rs | |
parent | d396881816cd256cb12d03deebea445cba99ea85 (diff) | |
download | arbs-553bbac36bdc483135a7053ca64507e01397e5e1.tar arbs-553bbac36bdc483135a7053ca64507e01397e5e1.tar.gz arbs-553bbac36bdc483135a7053ca64507e01397e5e1.zip |
add package manager recognition
Diffstat (limited to 'src/cli.rs')
-rw-r--r-- | src/cli.rs | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/src/cli.rs b/src/cli.rs new file mode 100644 index 0000000..6ffe03f --- /dev/null +++ b/src/cli.rs | |||
@@ -0,0 +1,25 @@ | |||
1 | use std::path::PathBuf; | ||
2 | |||
3 | use clap::{Parser, Subcommand}; | ||
4 | |||
5 | use crate::packages::Manager; | ||
6 | |||
7 | #[derive(Parser)] | ||
8 | pub struct Cli { | ||
9 | #[arg(short, long)] | ||
10 | pub config: Option<PathBuf>, | ||
11 | |||
12 | #[command(subcommand)] | ||
13 | pub subcommand: Subcommands, | ||
14 | } | ||
15 | |||
16 | #[derive(Subcommand)] | ||
17 | pub enum Subcommands { | ||
18 | GenerateConfig, | ||
19 | Save { | ||
20 | #[arg(short, long)] | ||
21 | package_manager: Option<Manager>, | ||
22 | }, | ||
23 | Restore, | ||
24 | } | ||
25 | |||