Skip to content

Commit

Permalink
Use termenv's EnvColorProfile, which respects NO_COLOR and CLICOLOR_F…
Browse files Browse the repository at this point in the history
…ORCE env vars
  • Loading branch information
muesli committed Feb 6, 2022
1 parent 9a06319 commit 7c939e8
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion examples/altscreen-toggle/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import (
)

var (
color = termenv.ColorProfile().Color
color = termenv.EnvColorProfile().Color
keyword = termenv.Style{}.Foreground(color("204")).Background(color("235")).Styled
help = termenv.Style{}.Foreground(color("241")).Styled
)
Expand Down
2 changes: 1 addition & 1 deletion examples/views/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ const (

// General stuff for styling the view
var (
term = termenv.ColorProfile()
term = termenv.EnvColorProfile()
keyword = makeFgStyle("211")
subtle = makeFgStyle("241")
progressEmpty = subtle(progressEmptyChar)
Expand Down

0 comments on commit 7c939e8

Please sign in to comment.