From dc873bc8b4a5889384b6bed95982dcdcebeba56d Mon Sep 17 00:00:00 2001 From: whut Date: Mon, 8 May 2023 11:25:26 -0500 Subject: [PATCH] put now-playing in quotes to avoid expansions --- tooner.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tooner.sh b/tooner.sh index fc3fd50..19bcd2b 100755 --- a/tooner.sh +++ b/tooner.sh @@ -2,7 +2,7 @@ ! pgrep mpd > /dev/null && mpd lastFile=/tmp/radioLast.$USER nowPlaying=`mpc current -f "[%artist% - ]%title%"` -nowPlaying=`echo $nowPlaying | sed 's/&/\&/g; s//\>/g; s/"/\"/g; s/'"'"'/\'/g'` +nowPlaying=`echo "$nowPlaying" | sed 's/&/\&/g; s//\>/g; s/"/\"/g; s/'"'"'/\'/g'` width=$((${#nowPlaying} > 30 ? ${#nowPlaying} : 30)) if [ $# -eq 0 ]; then