]> git.phdru.name Git - dotfiles.git/blobdiff - bin/xtitle
bin/xtitle: refactoring
[dotfiles.git] / bin / xtitle
index 6df8cdc282266507ad66b887b28e82fbdc0dbcaa..4c1cefc987e92d09ebefa7fda5670ccac1ddc971 100755 (executable)
@@ -7,12 +7,11 @@ case "$TERM" in
       else
          TITLE="$@"
       fi
-      echo -ne "\033]0;${TITLE}\007" # Set xterm caption
-   ;;
-esac
-
-case "$TERM" in
-   screen*)
-      echo -ne "\033k${TITLE}\033\\" # Set screen caption
+      echo -ne "\033]0;${TITLE}\007" # Set xterm title
+      case "$TERM" in
+         screen*)
+            echo -ne "\033k${TITLE}\033\\" # Set screen/tmux caption
+         ;;
+      esac
    ;;
 esac