$LOGNAME
–
Current login name
$LOGNAME
contains the login name of the current login session.
If $LOGNAME
is not set in the environment of the shell, it’s initialized to the string returned by the getlogin(3)
system call if available.
Links
BashSupport Pro is a Zsh IDE with support for $LOGNAME – try it now!