SYNOPSIS
tty [
DESCRIPTION
tty displays the file name of the terminal device associated with the standard input.
Options
-s -
does not display the name; the exit status of tty indicates whether or not the standard input is a terminal.
DIAGNOSTICS
Possible exit status values are:
- 0
-
Standard input is a terminal.
- 1
-
Standard input is not a terminal.
- 2
-
Failure because of unknown command line option, or too many arguments.
PORTABILITY
POSIX.2. x/OPEN Portability Guide 4.0. All UNIX systems. Windows 10. Windows Server 2016. Windows Server 2019. Windows 11. Windows Server 2022. Windows Server 2025.
The POSIX standard considers the
AVAILABILITY
PTC MKS Toolkit for Power Users
PTC MKS Toolkit for System Administrators
PTC MKS Toolkit for Developers
PTC MKS Toolkit for Interoperability
PTC MKS Toolkit for Professional Developers
PTC MKS Toolkit for Professional Developers 64-Bit Edition
PTC MKS Toolkit for Enterprise Developers
PTC MKS Toolkit for Enterprise Developers 64-Bit Edition
PTC MKS Toolkit 10.5 Documentation Build 40.