Browse Source

put now-playing in quotes to avoid expansions

master
whut 11 months ago
parent
commit
dc873bc8b4
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      tooner.sh

+ 1
- 1
tooner.sh View File

@@ -2,7 +2,7 @@
! pgrep mpd > /dev/null && mpd
lastFile=/tmp/radioLast.$USER
nowPlaying=`mpc current -f "[%artist% - ]%title%"`
nowPlaying=`echo $nowPlaying | sed 's/&/\&amp;/g; s/</\&lt;/g; s/>/\&gt;/g; s/"/\&quot;/g; s/'"'"'/\&#39;/g'`
nowPlaying=`echo "$nowPlaying" | sed 's/&/\&amp;/g; s/</\&lt;/g; s/>/\&gt;/g; s/"/\&quot;/g; s/'"'"'/\&#39;/g'`
width=$((${#nowPlaying} > 30 ? ${#nowPlaying} : 30))

if [ $# -eq 0 ]; then


Loading…
Cancel
Save