Skip to content

Commit

Permalink
Use aliases to get c/b/r shorthands for subcommands
Browse files Browse the repository at this point in the history
  • Loading branch information
MarijnS95 committed Sep 21, 2022
1 parent 1a89983 commit f047614
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions cargo-apk/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,16 +29,19 @@ struct Args {
#[derive(clap::Subcommand)]
enum ApkSubCmd {
/// Checks that the current package builds without creating an apk
#[clap(visible_alias = "c")]
Check {
#[clap(flatten)]
args: Args,
},
/// Compiles the current package and creates an apk
#[clap(visible_alias = "b")]
Build {
#[clap(flatten)]
args: Args,
},
/// Run a binary or example of the local package
#[clap(visible_alias = "r")]
Run {
#[clap(flatten)]
args: Args,
Expand All @@ -53,9 +56,6 @@ enum ApkSubCmd {
},
/// Print the version of cargo-apk
Version,
// TODO:
// Test {}
// Doc {}
}

fn main() -> anyhow::Result<()> {
Expand Down

0 comments on commit f047614

Please sign in to comment.