Set TMOUT depending on tty type.

This commit is contained in:
hjp 2004-06-22 10:03:03 +00:00
parent b09c5e1019
commit d8d2f44fff
2 changed files with 10 additions and 2 deletions

View File

@ -24,7 +24,6 @@ SAVEHIST=100
HISTSIZE=$SAVEHIST
HISTFILE=~/.zhistory
REPORTTIME=1
TMOUT=0
export PGPPATH=~/.pgp
export PARINIT=q1
export PARBODY=_A_a

11
.zshrc
View File

@ -54,4 +54,13 @@ cls() { clear; true }
source ~/.znewterm
TMOUT=3600
# assume pseudo terminals are from a "safe" terminal
# other terminals are probably from a console and should
# auto-logout after some time.
case `tty` in
/dev/pts/*)
TMOUT=0
;;
*)
TMOUT=3600
esac