Move all executables to wasm-utils-tools crate

This commit is contained in:
Wei Tang
2018-05-15 19:16:31 +08:00
parent b4a1fd88b3
commit d36a8cbacc
14 changed files with 29 additions and 99 deletions
+27
View File
@@ -0,0 +1,27 @@
#[macro_use] extern crate log;
#[macro_use] extern crate lazy_static;
extern crate env_logger;
use std::env;
use log::LevelFilter;
use env_logger::Builder;
lazy_static! {
static ref LOG_DUMMY: bool = {
let mut builder = Builder::new();
builder.filter(None, LevelFilter::Info);
if let Ok(log) = env::var("RUST_LOG") {
builder.parse(&log);
}
builder.init();
trace!("logger initialized");
true
};
}
/// Intialize log with default settings
pub fn init_log() {
let _ = *LOG_DUMMY;
}