ingress-nginx-helm/vendor/github.com/Sirupsen/logrus/terminal_check_notappengine.go
Manuel de Brito Fontes fe616fc9d7 Update go dependencies
2018-08-25 18:53:28 -03:00

19 lines
262 B
Go

// +build !appengine,!gopherjs
package logrus
import (
"io"
"os"
"golang.org/x/crypto/ssh/terminal"
)
func checkIfTerminal(w io.Writer) bool {
switch v := w.(type) {
case *os.File:
return terminal.IsTerminal(int(v.Fd()))
default:
return false
}
}