aboutsummaryrefslogtreecommitdiff
path: root/src/main.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/main.rs')
-rw-r--r--src/main.rs7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/main.rs b/src/main.rs
index 11f007f..df4d790 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -50,6 +50,10 @@ fn main() {
.takes_value(true)
.long("date")
.short("d"))
+ .arg(Arg::with_name("infer_date")
+ .help("Try to use the filename as date for the current log")
+ .global(true)
+ .long("infer-date"))
.arg(Arg::with_name("channel")
.help("Set a channel for the current log")
.global(true)
@@ -107,6 +111,7 @@ fn main() {
("seen", Some(args)) => app::seen::seen(args),
("sort", Some(args)) => app::sort::sort(args),
("dedup", Some(args)) => app::dedup::dedup(args),
- _ => panic!("Unimplemented subcommand, this is a bug")
+ (sc, _) if !sc.is_empty() => panic!("Unimplemented subcommand `{}`, this is a bug", sc),
+ _ => ()
}
}