Enable ANSI support on Windows 10
commitca865f9d260d9c34d49dff9c756758b4d31b1633
authorsharkdp <davidpeter@web.de>
dateSun 13 May 2018, 09:37 (8 years ago)
parent3ee0e56
src/app.rs+3
@@ -15,6 +15,9 @@ impl App {
1515 pub fn new() -> Self {
1616 let interactive_output = atty::is(Stream::Stdout);
1717
18+ #[cfg(windows)]
19+ let interactive_output = interactive_output && ansi_term::enable_ansi_support().is_ok();
20+
1821 App {
1922 matches: Self::matches(interactive_output),
2023 interactive_output,