diff options
author | fxqnlr <[email protected]> | 2024-08-14 23:51:43 +0200 |
---|---|---|
committer | fxqnlr <[email protected]> | 2024-08-14 23:51:43 +0200 |
commit | 371a77a994aeb0beae53f24a0edbf99d70133c33 (patch) | |
tree | efb9319063a6d9c32e2e13e3f1bb5cf804f05d37 /src/cli.rs | |
parent | 0cf179e17ac60f72aba85e978379fb0957ae7aaa (diff) | |
download | rsrclean-371a77a994aeb0beae53f24a0edbf99d70133c33.tar rsrclean-371a77a994aeb0beae53f24a0edbf99d70133c33.tar.gz rsrclean-371a77a994aeb0beae53f24a0edbf99d70133c33.zip |
add basic arguments
Diffstat (limited to 'src/cli.rs')
-rw-r--r-- | src/cli.rs | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/src/cli.rs b/src/cli.rs new file mode 100644 index 0000000..6b1a043 --- /dev/null +++ b/src/cli.rs | |||
@@ -0,0 +1,18 @@ | |||
1 | use std::path::PathBuf; | ||
2 | |||
3 | use clap::Parser; | ||
4 | |||
5 | #[derive(Parser, Clone)] | ||
6 | #[command(author, version, about, long_about = None)] | ||
7 | pub struct Args { | ||
8 | pub dir: Option<PathBuf>, | ||
9 | |||
10 | #[arg(short, long, default_value_t = 2)] | ||
11 | pub level: u8, | ||
12 | |||
13 | #[arg(short, long)] | ||
14 | pub doc: bool, | ||
15 | |||
16 | #[arg(long, default_value_t = true)] | ||
17 | pub dry_run: bool, | ||
18 | } | ||