From 7cadea0534979f4a31a68d2c30ba3c0b5202d4e9 Mon Sep 17 00:00:00 2001 From: Daniel Nephin Date: Fri, 27 Aug 2021 12:15:07 -0400 Subject: [PATCH] Fix color output on windows Use color.Output and color.Error so that color codes are handled properly on windows. --- cmd/main.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/cmd/main.go b/cmd/main.go index 6b86f90f..ffa08f8d 100644 --- a/cmd/main.go +++ b/cmd/main.go @@ -48,8 +48,8 @@ func setupFlags(name string) (*pflag.FlagSet, *options) { junitTestCaseClassnameFormat: &junitFieldFormatValue{}, junitTestSuiteNameFormat: &junitFieldFormatValue{}, postRunHookCmd: &commandValue{}, - stdout: os.Stdout, - stderr: os.Stderr, + stdout: color.Output, + stderr: color.Error, } flags := pflag.NewFlagSet(name, pflag.ContinueOnError) flags.SetInterspersed(false)