ttyname

package
v0.0.0-...-747faa2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 23, 2015 License: GPL-3.0 Imports: 8 Imported by: 0

README

ttyname(3) written in Go

func TtyName() returns a pointer to a string and nil or nil and an error if device name isn’t found.

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrNotFound = errors.New("Device not found")
	ErrNotTty   = errors.New("Not a tty device")
)
View Source
var (
	Stat = new(syscall.Stat_t)
)

Functions

func IsAtty

func IsAtty(fd uintptr) bool

quick IsAtty check

func TtyName

func TtyName(fd uintptr) (string, error)

Returns a string from a uintptr describing a file descriptor

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL