X-Git-Url: https://git.phdru.name/?a=blobdiff_plain;f=bin%2Fxtitle;h=f734659d5a4a9ea7d7f7f5e03b7adeeb4cb7068c;hb=5080a18901c90727c7dd11cc43bdefbad53f42c7;hp=4530949a0537f611ebe403e5fce63437510324b7;hpb=39d24747be9a09140eb9e18af2a305cef40c2be5;p=dotfiles.git diff --git a/bin/xtitle b/bin/xtitle index 4530949..f734659 100755 --- a/bin/xtitle +++ b/bin/xtitle @@ -1,4 +1,4 @@ -#! /usr/bin/env bash +#! /bin/sh case "$TERM" in *rxvt*|screen*|*term*|vt100) @@ -7,12 +7,11 @@ case "$TERM" in else TITLE="$@" fi - echo -ne "\033]0;${TITLE}\007" # Set xterm title - ;; -esac - -case "$TERM" in - screen*) - echo -ne "\033k${TITLE}\033\\" # Set screen/tmux caption + echo -n "\033]0;${TITLE}\007" # Set xterm title + case "$TERM" in + screen*) + echo -n "\033k${TITLE}\033\\" # Set screen/tmux caption + ;; + esac ;; esac