add debug test if tty or not

This commit is contained in:
Jakobus Schürz 2020-03-12 18:22:31 +01:00
parent 81793e06c3
commit 98b96b25e9

View file

@ -10,6 +10,12 @@ if [ -z ${SSHS+x} ]; then SSHS=false;fi
if [[ $- = *i* ]] ; then
#echo "interactive shell" >&2
case $(tty) in
/dev/tty[0-9]*)
echo "Run in TTY" ;;
*)
echo "Run in other terminal";;
esac
# define variables
[ -z "${MYSHELLCONFIIG_ROOT_TMOUT+x}" ] && MYSHELLCONFIIG_ROOT_TMOUT=500
[ -z "${MYSHELLCONFIIG_USER_TMOUT+x}" ] && MYSHELLCONFIIG_USER_TMOUT=0