Sign in
go
/
gddo
/
8b95641ad7be5798b6c19f34605e8d22c5f7fa41
/
.
/
vendor
/
github.com
/
inconshreveable
/
log15
/
term
/
terminal_solaris.go
blob: 033c163246eeb6e9146b22a9d96a53d33c38d12c [
file
] [
log
] [
blame
]
package term
import "golang.org/x/sys/unix"
// IsTty returns true if the given file descriptor is a terminal.
func IsTty(fd uintptr) bool {
_, err := unix.IoctlGetTermios(int(fd), unix.TCGETA)
return err == nil
}