diff options
-rw-r--r-- | bin/core/imag/Cargo.toml | 6 | ||||
-rw-r--r-- | bin/core/imag/src/main.rs | 7 |
2 files changed, 12 insertions, 1 deletions
diff --git a/bin/core/imag/Cargo.toml b/bin/core/imag/Cargo.toml index 77472b8c..d40da6c3 100644 --- a/bin/core/imag/Cargo.toml +++ b/bin/core/imag/Cargo.toml @@ -33,7 +33,6 @@ log = "0.4.0" toml = "0.4" toml-query = "0.7" -libimagrt = { version = "0.9.0", path = "../../../lib/core/libimagrt" } libimagerror = { version = "0.9.0", path = "../../../lib/core/libimagerror" } [dependencies.clap] @@ -41,3 +40,8 @@ version = "^2.29" default-features = false features = ["suggestions", "color", "wrap_help"] +[dependencies.libimagrt] +version = "0.9.0" +path = "../../../lib/core/libimagrt" +features = ["pub_logging_initialization"] + diff --git a/bin/core/imag/src/main.rs b/bin/core/imag/src/main.rs index 37279dd0..12fc8d4e 100644 --- a/bin/core/imag/src/main.rs +++ b/bin/core/imag/src/main.rs @@ -60,6 +60,7 @@ use libimagrt::spec::CliSpec; use libimagerror::io::ToExitCode; use libimagerror::exit::ExitUnwrap; use libimagerror::trace::trace_error; +use libimagrt::configuration::InternalConfiguration; /// Returns the helptext, putting the Strings in cmds as possible /// subcommands into it @@ -182,7 +183,9 @@ fn main() { } } + let enable_logging = app.enable_logging(); let matches = app.matches(); + let rtp = ::libimagrt::runtime::get_rtp_match(&matches); let configpath = matches .value_of(Runtime::arg_config_name()) @@ -194,6 +197,10 @@ fn main() { exit(1) }); + if enable_logging { + Runtime::init_logger(&matches, config.as_ref()) + } + debug!("matches: {:?}", matches); // Begin checking for arguments |