Merge pull request #632 from dawidd6/master

MPD server on another host
This commit is contained in:
Dylan Araps 2017-01-24 12:00:09 +11:00 committed by GitHub
commit 539c1462bf

View file

@ -1332,6 +1332,10 @@ get_song() {
song="$(dbus-send --print-reply --dest=net.sacredchao.QuodLibet /net/sacredchao/QuodLibet net.sacredchao.QuodLibet.CurrentSong |\
awk -F'"' '/artist/ {getline; a=$2} /title/ {getline; t=$2} END{print a " - " t}')"
;;
*)
mpc >/dev/null 2>&1 && song="$(mpc current)"
;;
esac
[[ "$(trim "$song")" = "-" ]] && unset -v song