Merge branch 'command_help' into 'master'

fix: remove unnecessary information in help commands

See merge request veretcle/scootaloo!31
This commit is contained in:
VC
2022-11-18 12:31:17 +00:00
3 changed files with 4 additions and 7 deletions

2
Cargo.lock generated
View File

@@ -2103,7 +2103,7 @@ dependencies = [
[[package]] [[package]]
name = "scootaloo" name = "scootaloo"
version = "0.9.2" version = "0.9.3"
dependencies = [ dependencies = [
"chrono", "chrono",
"clap", "clap",

View File

@@ -1,6 +1,6 @@
[package] [package]
name = "scootaloo" name = "scootaloo"
version = "0.9.2" version = "0.9.3"
authors = ["VC <veretcle+framagit@mateu.be>"] authors = ["VC <veretcle+framagit@mateu.be>"]
edition = "2021" edition = "2021"

View File

@@ -15,10 +15,7 @@ fn main() {
.short('c') .short('c')
.long("config") .long("config")
.value_name("CONFIG_FILE") .value_name("CONFIG_FILE")
.help(&format!( .help("TOML config file for scootaloo")
"TOML config file for scootaloo (default {})",
DEFAULT_CONFIG_PATH
))
.num_args(1) .num_args(1)
.default_value(DEFAULT_CONFIG_PATH) .default_value(DEFAULT_CONFIG_PATH)
.display_order(1), .display_order(1),
@@ -28,7 +25,7 @@ fn main() {
.short('l') .short('l')
.long("loglevel") .long("loglevel")
.value_name("LOGLEVEL") .value_name("LOGLEVEL")
.help("Log level.Valid values are: Off, Warn, Error, Info, Debug") .help("Log level")
.num_args(1) .num_args(1)
.value_parser(["Off", "Warn", "Error", "Info", "Debug"]) .value_parser(["Off", "Warn", "Error", "Info", "Debug"])
.display_order(2), .display_order(2),