minio/vendor/github.com/mattn/go-isatty
2017-02-08 22:27:35 -08:00
..
doc.go First time mode for controller 2015-10-04 16:42:16 -07:00
isatty_appengine.go Make minio server compile on OpenBSD, NetBSD, Solaris (#3719) 2017-02-08 22:27:35 -08:00
isatty_bsd.go Make minio server compile on OpenBSD, NetBSD, Solaris (#3719) 2017-02-08 22:27:35 -08:00
isatty_linux.go vendorize: update all vendorized packages. (#2206) 2016-07-14 14:59:20 -07:00
isatty_solaris.go vendorize: update all vendorized packages. (#2206) 2016-07-14 14:59:20 -07:00
isatty_windows.go vendorize: update all vendorized packages. (#2206) 2016-07-14 14:59:20 -07:00
LICENSE First time mode for controller 2015-10-04 16:42:16 -07:00
README.md First time mode for controller 2015-10-04 16:42:16 -07: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)