Skip to content
Snippets Groups Projects
  • Volker Schukai's avatar
    562eff45
    chore: task · 562eff45
    Volker Schukai authored
    chore: Update vendorHash to null
    
    chore: Update vendorHash to null
    
    chore: update go
    
    chore: Update vendorHash to null
    
    chore: update
    
    chore: update
    
    chore: UPdate
    
    chore: Update vendorHash to null
    
    chore: update
    
    chore: Update vendorHash to sha256-6zNRYYddNcOx6G9wSKGv89CfSCxrG0qpSDfBStwNdks=
    
    chore: update
    
    x
    
    x
    
    u
    
    x
    
    x
    Verified
    562eff45
    History
    chore: task
    Volker Schukai authored
    chore: Update vendorHash to null
    
    chore: Update vendorHash to null
    
    chore: update go
    
    chore: Update vendorHash to null
    
    chore: update
    
    chore: update
    
    chore: UPdate
    
    chore: Update vendorHash to null
    
    chore: update
    
    chore: Update vendorHash to sha256-6zNRYYddNcOx6G9wSKGv89CfSCxrG0qpSDfBStwNdks=
    
    chore: update
    
    x
    
    x
    
    u
    
    x
    
    x
isatty_plan9.go 509 B
//go:build plan9
// +build plan9

package isatty

import (
	"syscall"
)

// IsTerminal returns true if the given file descriptor is a terminal.
func IsTerminal(fd uintptr) bool {
	path, err := syscall.Fd2path(int(fd))
	if err != nil {
		return false
	}
	return path == "/dev/cons" || path == "/mnt/term/dev/cons"
}

// IsCygwinTerminal return true if the file descriptor is a cygwin or msys2
// terminal. This is also always false on this environment.
func IsCygwinTerminal(fd uintptr) bool {
	return false
}