in reply to More than one way to do it???
perl -we '$tty=qx(tty);$tty=~s!^/dev/!!;print $tty' [download]