tty: Print filename of terminal on stdin

Print file name of terminal on standard input, print the file
name of the terminal connected to standard input. It prints `not a tty? if standard
input is not a terminal.
SYNTAX
tty [option]...

OPTIONS

-s
--silent
--quiet
Print nothing; only return an exit status.

Exit status:

0 if standard input is a terminal
1 if standard input is not a terminal
2 if given incorrect arguments
3 if a write error occurs
"Behind every great fortune there is a crime" - Honore
de Balzac
Tags
Comments
Write the first comment
Leave a trace
Name *
Email *
Website
Anti SPAM * Code (4 + 1) =
Leave me a comment *
 
All comments are subject to editorial review
Post being viewed right now
Item date: 14.05.2009
Views: 1270
Item date: 14.12.2009
Views: 1806
Item date: 17.06.2009
Views: 1184
Item date: 02.01.2009
Views: 729
Item date: 01.01.2009
Views: 1325
Item date: 11.04.2009
Views: 1030
Item date: 19.07.2009
Views: 1335
Item date: 10.09.2009
Views: 1741
Item date: 15.05.2009
Views: 1786
Item date: 21.07.2009
Views: 1189