enable ansi terminal on windows 10 cmd

This commit is contained in:
2022-03-28 22:29:45 +02:00
parent 7197c11586
commit 6c064a1dd8
3 changed files with 6 additions and 1 deletions

View File

@@ -15,6 +15,9 @@ use uw8::Runtime;
fn main() -> Result<()> {
let mut args = Arguments::from_env();
// try to enable ansi support in win10 cmd shell
let _ = ansi_term::enable_ansi_support();
match args.subcommand()?.as_deref() {
Some("version") => {
println!("{}", env!("CARGO_PKG_VERSION"));