From 30625ba3ba323aa948330e5c003bfe932dd19299 Mon Sep 17 00:00:00 2001 From: Rekai Musuka Date: Sun, 4 Apr 2021 18:01:09 -0500 Subject: [PATCH] chore: replace strings with macros --- src/main.rs | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/main.rs b/src/main.rs index 270a6c8..cfa7a99 100644 --- a/src/main.rs +++ b/src/main.rs @@ -1,4 +1,4 @@ -use clap::{App, Arg, SubCommand}; +use clap::{crate_authors, crate_description, crate_name, crate_version, App, Arg, SubCommand}; use directories::ProjectDirs; use domasi::Alert; use domasi::Domasi; @@ -6,10 +6,10 @@ use std::fs; use std::path::PathBuf; fn main() { - let app = App::new("Domasi") - .version("0.1.0") - .author("Rekai Musuka ") - .about("CLI Pomodoro Timer") + let app = App::new(crate_name!()) + .version(crate_version!()) + .author(crate_authors!()) + .about(crate_description!()) .arg( Arg::with_name("create-alert-dir") .short("C") @@ -30,7 +30,7 @@ fn main() { } match matches.subcommand() { - ("start", Some(_sub_match)) => { + ("start", Some(_)) => { let mut domasi: Domasi = Default::default(); match get_alert() {