-
Notifications
You must be signed in to change notification settings - Fork 706
Open
Description
diff --git a/ttycolors.go b/ttycolors.go
index fe63c1a..a5228b5 100644
--- a/ttycolors.go
+++ b/ttycolors.go
@@ -2,7 +2,7 @@ package web
import (
"golang.org/x/crypto/ssh/terminal"
- "syscall"
+ "os"
)
var ttyCodes struct {
@@ -22,7 +22,7 @@ func ttyBold(code string) string {
}
func ttyEscape(code string) string {
- if terminal.IsTerminal(syscall.Stdout) {
+ if terminal.IsTerminal(int(os.Stdout.Fd())) {
return "\x1b[" + code + "m"
} else {
return ""
Metadata
Metadata
Assignees
Labels
No labels