aboutsummaryrefslogtreecommitdiff
path: root/bash/bashrc
diff options
context:
space:
mode:
Diffstat (limited to 'bash/bashrc')
-rw-r--r--bash/bashrc15
1 files changed, 15 insertions, 0 deletions
diff --git a/bash/bashrc b/bash/bashrc
index ffc5039d..57d6719d 100644
--- a/bash/bashrc
+++ b/bash/bashrc
@@ -69,3 +69,18 @@ if [ $? -eq 0 ]; then
export EDITOR=vi
fi
+# Terminal-specific settings.
+case "$TERM" in
+
+ # Set title of screen/tmux window.
+ screen*)
+ printf "\033k$(hostname)\033\\"
+ ;;
+
+ # Set xterm title, use 256 colors.
+ xterm*)
+ PS1="\[\e]0;\h\a\]${PS1}"
+ TERM=xterm-256color
+ ;;
+esac
+