This commit is contained in:
n4n5
2024-06-19 09:08:10 +02:00
committed by andy.boot
parent 028ca1fdc7
commit 08e4240b41
10 changed files with 55 additions and 11 deletions
+5
View File
@@ -31,6 +31,7 @@ pub struct Config {
pub stack_size: Option<usize>,
pub threads: Option<usize>,
pub output_json: Option<bool>,
pub print_errors: Option<bool>,
}
impl Config {
@@ -102,6 +103,10 @@ impl Config {
pub fn get_only_dir(&self, options: &ArgMatches) -> bool {
Some(true) == self.only_dir || options.get_flag("only_dir")
}
pub fn get_print_errors(&self, options: &ArgMatches) -> bool {
Some(true) == self.print_errors || options.get_flag("print_errors")
}
pub fn get_only_file(&self, options: &ArgMatches) -> bool {
Some(true) == self.only_file || options.get_flag("only_file")
}