Fix verbosity serialization
Forgot the serde defaults which lead to problems on some terminals
@@ -83,6 +83,7 @@ default_function! {
timeout: usize = DEFAULT_TIMEOUT_SECS;
retry_wait_time: usize = DEFAULT_RETRY_WAIT_TIME_SECS;
method: String = DEFAULT_METHOD.to_string();
+ verbosity: Verbosity<WarnLevel> = Verbosity::new(1, 0);
}
// Macro for merging configuration values
@@ -142,6 +143,7 @@ impl LycheeOptions {
pub(crate) struct Config {
/// Verbose program output
#[clap(flatten)]
+ #[serde(default = "verbosity")]
pub(crate) verbose: Verbosity<WarnLevel>,
/// Do not show progress bar.
@@ -363,7 +365,7 @@ impl Config {
self, toml;
// Keys with defaults to assign
- verbose: Verbosity::new(0, 0);
+ verbose: Verbosity::new(1, 0);
cache: false;
no_progress: false;
max_redirects: DEFAULT_MAX_REDIRECTS;
