Make use of Cargo environment variables.

This commit is contained in:
shy 2021-04-07 07:48:53 +02:00
parent 3f1ac39527
commit d894d6d475

View file

@ -19,10 +19,10 @@ use alarm::{Countdown, AlarmRoster, alarm_exec};
use layout::{Layout, Position}; use layout::{Layout, Position};
const NAME: &str = "kitchentimer"; const NAME: &str = env!("CARGO_PKG_NAME");
const VERSION: &str = "0.0.1"; const VERSION: &str = env!("CARGO_PKG_VERSION");
const USAGE: &str = const USAGE: &str = concat!("USAGE: ", env!("CARGO_PKG_NAME"),
"USAGE: kitchentimer [-h|-v] [-p] [ALARM TIME(s)] [-e|--exec COMMAND [...]] " [-h|-v] [-p] [ALARM TIME(s)] [-e|--exec COMMAND [...]]
PARAMETERS: PARAMETERS:
[ALARM TIME] None or multiple alarm times (HH:MM:SS). [ALARM TIME] None or multiple alarm times (HH:MM:SS).
OPTIONS: OPTIONS:
@ -35,7 +35,7 @@ OPTIONS:
with the elapsed time in (HH:)MM:SS format. with the elapsed time in (HH:)MM:SS format.
SIGNALS: <SIGUSR1> Reset clock. SIGNALS: <SIGUSR1> Reset clock.
<SIGUSR2> Pause or un-pause clock."; <SIGUSR2> Pause or un-pause clock.");
const MENUBAR: &str = const MENUBAR: &str =
"[0-9] Add alarm [d] Delete alarm [SPACE] Pause [r] Reset [c] Clear color [q] Quit"; "[0-9] Add alarm [d] Delete alarm [SPACE] Pause [r] Reset [c] Clear color [q] Quit";
const MENUBAR_SHORT: &str = const MENUBAR_SHORT: &str =