From a4d6a0801a7d17564a9f3c055a5820d3f652f9bd Mon Sep 17 00:00:00 2001 From: Tobie Morgan Hitchcock Date: Wed, 15 Nov 2017 18:18:38 +0000 Subject: [PATCH] Update to latest logrus package --- log/text.go | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/log/text.go b/log/text.go index 5ee91d19..a3a731c9 100644 --- a/log/text.go +++ b/log/text.go @@ -26,6 +26,8 @@ import ( "github.com/mgutz/ansi" "github.com/Sirupsen/logrus" + + "golang.org/x/crypto/ssh/terminal" ) const clear = ansi.Reset @@ -36,7 +38,7 @@ var ( ) func init() { - isTerminal = logrus.IsTerminal(os.Stdout) + isTerminal = terminal.IsTerminal(int(os.Stdout.Fd())) isColoured = isTerminal && (runtime.GOOS != "windows") }