Add the launch of tmux, if available.

This commit is contained in:
Scott Wallace 2015-09-23 22:10:35 +01:00
parent c894899c2a
commit 77e9a05e9c

14
.bashrc
View file

@ -75,3 +75,17 @@ for FILE in ~/.bash/auto_complete.d/*; do source ${FILE}; done
#-------------------------------------------------------------------------------- #--------------------------------------------------------------------------------
[ -f ~/.bashrc_local ] && source ~/.bashrc_local [ -f ~/.bashrc_local ] && source ~/.bashrc_local
#--------------------------------------------------------------------------------
# Launch tmux, if available
#--------------------------------------------------------------------------------
if which tmux &> /dev/null; then
if ! tmux attach &> /dev/null; then
if [[ ! $TERM =~ screen ]]; then
exec tmux
fi
else
exit
fi
fi
#--------------------------------------------------------------------------------