diff options
author | Rasmus Steinke <rasi@xssn.at> | 2014-08-06 21:47:26 +0200 |
---|---|---|
committer | Rasmus Steinke <rasi@xssn.at> | 2014-08-06 21:47:26 +0200 |
commit | 7125826c1ff348309c4184a80d070185f769bba3 (patch) | |
tree | 66c5e79ce7c9d4acb108578a48e74f961260ae09 /clerk | |
parent | 772fed2246e9ddad9c549c6f4575203e65550f8b (diff) | |
download | perl-app-clerk-7125826c1ff348309c4184a80d070185f769bba3.tar.gz perl-app-clerk-7125826c1ff348309c4184a80d070185f769bba3.tar.xz |
test fix for ssh lastfm
Diffstat (limited to 'clerk')
-rwxr-xr-x | clerk | 26 |
1 files changed, 13 insertions, 13 deletions
@@ -249,21 +249,21 @@ export status="$(mpc status)" repeat=$(echo "$status" | tail -1 | awk -F ':' '{ print $3 }' | cut -d ' ' -f 2) -mpds_check="$(ssh $ssh_host -q -t 'bash -c "pgrep mpdscribble"')" - if ((ssh_lastfm)); then - if [ -n "$mpds_check" ]; - then export scrobble=on - else export scrobble=off - fi + if [[ "$ssh_lastfm" == "1" ]]; then + mpds_check="$(ssh $ssh_host -q -t 'bash -c "pgrep mpdscribble"')" + if [ -n "$mpds_check" ]; + then export scrobble=on + else export scrobble=off + fi + else + if pgrep mpdscribble + then + export scrobble=on else - if pgrep mpdscribble - then - export scrobble=on - else - export scrobble=off - fi - fi + export scrobble=off + fi + fi export rgain="$(mpc replaygain | cut -d ' ' -f 2)" |