TTY=$(tty); export TTY=${TTY##*/};
if [[ "$TTY" == "tty1" ]]; then
unset TMOUT; # so that this value does not get propagated
>"/tmp/$USER.$TTY/startx.log"
exec startx 2>&1 | tee "/tmp/$USER.$TTY/startx.log" & disown %1
export TMOUT=120; # set console shell to logout after 2 minutes
fi
if [[ "$TTY" == "tty1" ]]; then
unset TMOUT; # so that this value does not get propagated
>"/tmp/$USER.$TTY/startx.log"
exec startx 2>&1 | tee "/tmp/$USER.$TTY/startx.log" & disown %1
export TMOUT=120; # set console shell to logout after 2 minutes
fi
Views - Today : 280 Total : 280
Comments :