From 3dd9cc4ea97050cbfe0cf11de36770b71c2f606e Mon Sep 17 00:00:00 2001 From: Jake Howard Date: Thu, 20 Jul 2017 09:24:04 +0100 Subject: [PATCH] set verbosity level on config --- src/config/mod.rs | 3 ++- src/main.rs | 4 ++-- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/config/mod.rs b/src/config/mod.rs index 9b17854..2676650 100644 --- a/src/config/mod.rs +++ b/src/config/mod.rs @@ -13,7 +13,8 @@ pub mod validate_types; pub struct Config { pub input: Vec, pub output: HashMap, - pub title: String + pub title: String, + pub verbosity: u64, } impl Config { diff --git a/src/main.rs b/src/main.rs index 28b5172..fb5119b 100644 --- a/src/main.rs +++ b/src/main.rs @@ -5,7 +5,6 @@ extern crate serde_derive; extern crate serde_yaml; - mod args; mod config; mod process; @@ -17,7 +16,8 @@ mod tests; fn main() { let args = args::get_matches(); if args.subcommand_name().unwrap() == "build" { - let config = config::get_config(); + let mut config = config::get_config(); + config.verbosity = args::get_verbose(args); process::build(config); } }