Skip to content

Commit

Permalink
fix: check CI value
Browse files Browse the repository at this point in the history
  • Loading branch information
aymanbagabas committed Jul 5, 2023
1 parent 410c7da commit 8aac93e
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions termenv.go
Original file line number Diff line number Diff line change
Expand Up @@ -30,8 +30,7 @@ func (o *Output) isTTY() bool {
return true
}

// FIXME: should check for its value instead of length
if len(o.environ.Getenv("CI")) > 0 {
if isCI, err := strconv.ParseBool(o.environ.Getenv("CI")); err == nil && isCI {
return false
}

Expand Down

0 comments on commit 8aac93e

Please sign in to comment.