Skip to content

Commit

Permalink
Merge pull request #32 from oliverpool/patch-1
Browse files Browse the repository at this point in the history
Fix handling of the IS_NO_COLOR env variable
  • Loading branch information
matryer committed Nov 20, 2019
2 parents 9fde238 + 71568e0 commit 03891c8
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions is.go
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,8 @@ type I struct {
var noColorFlag bool

func init() {
colorEnv := os.Getenv("IS_NO_COLOR") != "false"
flag.BoolVar(&noColorFlag, "nocolor", colorEnv, "turns off colors")
envNoColor := os.Getenv("IS_NO_COLOR") == "true"
flag.BoolVar(&noColorFlag, "nocolor", envNoColor, "turns off colors")
}

// New makes a new testing helper using the specified
Expand Down

0 comments on commit 03891c8

Please sign in to comment.