mirror of
https://github.com/go-task/task.git
synced 2024-12-04 10:24:45 +02:00
12 lines
165 B
Go
12 lines
165 B
Go
package term
|
|
|
|
import (
|
|
"os"
|
|
|
|
"golang.org/x/term"
|
|
)
|
|
|
|
func IsTerminal() bool {
|
|
return term.IsTerminal(int(os.Stdin.Fd())) && term.IsTerminal(int(os.Stdout.Fd()))
|
|
}
|