From: Chris Koeritz Date: Wed, 31 Aug 2016 12:57:15 +0000 (-0400) Subject: wrapped use of xprop with a check that it exists. X-Git-Tag: 2.140.90~490 X-Git-Url: https://feistymeow.org/gitweb/?a=commitdiff_plain;h=264df59e89898f1b2a8c45b2531577d2726a546e;p=feisty_meow.git wrapped use of xprop with a check that it exists. --- diff --git a/customizing/fred/scripts/ssh.sh b/customizing/fred/scripts/ssh.sh index 13d57fa3..4d006037 100644 --- a/customizing/fred/scripts/ssh.sh +++ b/customizing/fred/scripts/ssh.sh @@ -6,8 +6,11 @@ source "$FEISTY_MEOW_LOADING_DOCK/custom/scripts/pick_credentials.sh" # save the former terminal title if we're running in X with xterm. prior_title= -if [ "$TERM" == "xterm" ]; then - prior_title="$(xprop -id $WINDOWID | perl -nle 'print $1 if /^WM_NAME.+= \"(.*)\"$/')" +which xprop &>/dev/null +if [ $? -eq 0 ]; then + if [ "$TERM" == "xterm" ]; then + prior_title="$(xprop -id $WINDOWID | perl -nle 'print $1 if /^WM_NAME.+= \"(.*)\"$/')" + fi fi # force the TERM variable to a more generic version for other side.