Make mediaplater block escape ampersand

master
Jonathan Hodgson 7 years ago
parent ec0ea497d5
commit 870cd47378
  1. 10
      i3/blocks/mediaplayer

@ -15,7 +15,13 @@ else
colour="#FF8000"
fi
ret="<span foreground='$colour'>$($COMMAND metadata title)</span>"
ret="$ret - $($COMMAND metadata artist)"
title=$($COMMAND metadata title | sed "s/\&/\&amp;/g")
artist=$($COMMAND metadata artist | sed "s/\&/\&amp;/g")
ret="<span foreground='$colour'>$title</span>"
ret="$ret - $artist"
echo "$ret";

Loading…
Cancel
Save