summaryrefslogtreecommitdiffstats
path: root/src/cli.rs
diff options
context:
space:
mode:
authorMatthias Beyer <matthias.beyer@atos.net>2019-04-30 14:39:39 +0200
committerMatthias Beyer <matthias.beyer@atos.net>2019-04-30 16:30:49 +0200
commit030dd838277e7868a1f73b0edf518fa4b0849c2d (patch)
tree2d83b040d27187b5c80cd2e7b021508ad1c59b6e /src/cli.rs
parent632b7e43de2df4f90da0fe14d85fae8aac13b151 (diff)
Add: Feature to sort output
Diffstat (limited to 'src/cli.rs')
-rw-r--r--src/cli.rs34
1 files changed, 34 insertions, 0 deletions
diff --git a/src/cli.rs b/src/cli.rs
index cf06dbe..c04052c 100644
--- a/src/cli.rs
+++ b/src/cli.rs
@@ -62,6 +62,23 @@ pub fn build_cli<'a>() -> App<'a, 'a> {
.takes_value(true)
.help("Query data about a project")
)
+
+ .arg(Arg::with_name("sort-version")
+ .long("sort-version")
+ .required(false)
+ .multiple(false)
+ .takes_value(false)
+ .help("Sort output by version")
+ .conflicts_with("sort-repo")
+ )
+ .arg(Arg::with_name("sort-repo")
+ .long("sort-repo")
+ .required(false)
+ .multiple(false)
+ .takes_value(false)
+ .help("Sort output by repository")
+ .conflicts_with("sort-version")
+ )
)
.subcommand(SubCommand::with_name("problems")
@@ -89,6 +106,23 @@ pub fn build_cli<'a>() -> App<'a, 'a> {
.args(&["repo", "maintainer"])
.required(true))
+
+ .arg(Arg::with_name("sort-maintainer")
+ .long("sort-maintainer")
+ .required(false)
+ .multiple(false)
+ .takes_value(false)
+ .help("Sort output by maintainer")
+ .conflicts_with("sort-repo")
+ )
+ .arg(Arg::with_name("sort-repo")
+ .long("sort-repo")
+ .required(false)
+ .multiple(false)
+ .takes_value(false)
+ .help("Sort output by repository")
+ .conflicts_with("sort-maintainer")
+ )
)
.subcommand(SubCommand::with_name("compare")