diff options
| author | diogo464 <[email protected]> | 2024-01-01 19:01:25 +0000 |
|---|---|---|
| committer | diogo464 <[email protected]> | 2024-01-01 19:01:25 +0000 |
| commit | 6110910269b7b5fac8c6fdc767d11f5fe16404d7 (patch) | |
| tree | 30681a5284f41ea9f06779d730e2f5fae6b720da /src | |
| parent | 6ed294aceebf7515ed62785785fd9703f7e6af41 (diff) | |
added cli descriptions
Diffstat (limited to 'src')
| -rw-r--r-- | src/main.rs | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/main.rs b/src/main.rs index e31764d..190f258 100644 --- a/src/main.rs +++ b/src/main.rs | |||
| @@ -24,15 +24,20 @@ enum Subcommand { | |||
| 24 | Prune(PruneArgs), | 24 | Prune(PruneArgs), |
| 25 | } | 25 | } |
| 26 | 26 | ||
| 27 | /// Run the zsnap daemon. | ||
| 28 | /// | ||
| 29 | /// This command will periodically create and prune snapshots according to the configuration file. | ||
| 27 | #[derive(Debug, Parser)] | 30 | #[derive(Debug, Parser)] |
| 28 | struct RunArgs {} | 31 | struct RunArgs {} |
| 29 | 32 | ||
| 33 | /// Create a snapshot. | ||
| 30 | #[derive(Debug, Parser)] | 34 | #[derive(Debug, Parser)] |
| 31 | struct SnapshotArgs { | 35 | struct SnapshotArgs { |
| 32 | /// the tag to snapshot with | 36 | /// the tag to snapshot with |
| 33 | #[clap(long)] | 37 | #[clap(long)] |
| 34 | tag: String, | 38 | tag: String, |
| 35 | 39 | ||
| 40 | /// whether to snapshot recursively | ||
| 36 | #[clap(long)] | 41 | #[clap(long)] |
| 37 | recursive: bool, | 42 | recursive: bool, |
| 38 | 43 | ||
| @@ -40,6 +45,7 @@ struct SnapshotArgs { | |||
| 40 | dataset: Vec<String>, | 45 | dataset: Vec<String>, |
| 41 | } | 46 | } |
| 42 | 47 | ||
| 48 | /// Prune snapshots. | ||
| 43 | #[derive(Debug, Parser)] | 49 | #[derive(Debug, Parser)] |
| 44 | struct PruneArgs { | 50 | struct PruneArgs { |
| 45 | /// the tag to prune | 51 | /// the tag to prune |
