From 777cd7e81529b50b8a1b0f4ee0b058b8507beda5 Mon Sep 17 00:00:00 2001 From: Chester Liu Date: Sat, 17 Apr 2021 17:56:20 +0800 Subject: [PATCH] Explicitly enable vt processing on Windows --- src/main.rs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/main.rs b/src/main.rs index 84f36b7..1ff32ba 100644 --- a/src/main.rs +++ b/src/main.rs @@ -50,6 +50,11 @@ fn main() { logger::configure(env::var_os(vars::EXA_DEBUG)); + #[cfg(windows)] + if let Err(e) = ansi_term::enable_ansi_support() { + warn!("Failed to enable ANSI support: {}", e); + } + let args: Vec<_> = env::args_os().skip(1).collect(); match Options::parse(args.iter().map(|e| e.as_ref()), &LiveVars) { OptionsResult::Ok(options, mut input_paths) => {