14 lines
300 B
Go
Raw Normal View History

2024-03-05 17:47:02 +01:00
package color
import (
"os"
2024-03-12 00:25:20 +01:00
"git.akyoto.dev/go/color/tty"
2024-03-05 17:47:02 +01:00
)
2024-03-21 23:23:43 +01:00
// Terminal indicates if we're in a terminal with truecolor support.
var Terminal = tty.IsTerminal(os.Stdout.Fd())
// TrueColor indicates if the terminal has 24-bit color support.
var TrueColor = os.Getenv("COLORTERM") == "truecolor"