orbiter/vendor/github.com/mattn/go-isatty
Lorenzo Fontana 3b7a061574
Sync dependencies with ensure
Remove old lock file

Signed-off-by: Lorenzo Fontana <lo@linux.com>
2017-08-21 00:14:21 +02:00
..
_example Sync dependencies with ensure 2017-08-21 00:14:21 +02:00
doc.go First commit 2017-02-21 00:07:57 +00:00
isatty_appengine.go First commit 2017-02-21 00:07:57 +00:00
isatty_bsd.go Updated dep version and dependencies 2017-07-10 10:33:29 +02:00
isatty_linux.go First commit 2017-02-21 00:07:57 +00:00
isatty_solaris.go First commit 2017-02-21 00:07:57 +00:00
isatty_windows.go First commit 2017-02-21 00:07:57 +00:00
LICENSE First commit 2017-02-21 00:07:57 +00:00
README.md First commit 2017-02-21 00:07:57 +00:00

go-isatty

isatty for golang

Usage

package main

import (
	"fmt"
	"github.com/mattn/go-isatty"
	"os"
)

func main() {
	if isatty.IsTerminal(os.Stdout.Fd()) {
		fmt.Println("Is Terminal")
	} else {
		fmt.Println("Is Not Terminal")
	}
}

Installation

$ go get github.com/mattn/go-isatty

License

MIT

Author

Yasuhiro Matsumoto (a.k.a mattn)