Add -v option to print out logs (>= info) (#164)
This commit is contained in:
committed by
Roey Darwish Dror
parent
680f9a6d19
commit
232c886be6
@@ -117,6 +117,10 @@ pub struct CommandLineArgs {
|
||||
/// Do not perform upgrades for the given steps
|
||||
#[structopt(long = "disable", raw(possible_values = "&Step::possible_values()"))]
|
||||
disable: Vec<Step>,
|
||||
|
||||
/// Output logs
|
||||
#[structopt(short = "v", long = "verbose")]
|
||||
verbose: bool,
|
||||
}
|
||||
|
||||
/// Represents the application configuration
|
||||
@@ -189,4 +193,9 @@ impl Config {
|
||||
pub fn no_retry(&self) -> bool {
|
||||
self.opt.no_retry
|
||||
}
|
||||
|
||||
/// Tell whether we should print log.
|
||||
pub fn verbose(&self) -> bool {
|
||||
self.opt.verbose
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user