diff options
author | Rasmus Steinke <rasi@xssn.at> | 2015-09-05 08:38:50 +0200 |
---|---|---|
committer | Rasmus Steinke <rasi@xssn.at> | 2015-09-05 08:38:50 +0200 |
commit | 56a55f9638fe1a8bd674dcd8a7f4874d3479db5a (patch) | |
tree | c2bce80d4f713f697b734ff04c376957866fc179 /clerk | |
parent | 6dcfab517f12968225c1a36ce1bdbfdd824ecf84 (diff) | |
download | perl-app-clerk-56a55f9638fe1a8bd674dcd8a7f4874d3479db5a.tar.gz perl-app-clerk-56a55f9638fe1a8bd674dcd8a7f4874d3479db5a.tar.xz |
fix highlight
Diffstat (limited to 'clerk')
-rwxr-xr-x | clerk | 14 |
1 files changed, 12 insertions, 2 deletions
@@ -666,7 +666,10 @@ songs () { elif [[ $val -eq 24 ]]; then mpc next - POS=$(echo $(( $POS +1 ))) + mpd_play=$(mpc status | mpc status | grep -E '\[playing\]|\[paused\]') + if [[ -n ${mpd_play} ]]; then + POS=$(echo $(( $(mpc current -f '%position%') + 0 ))) + fi elif [[ $val -eq 25 ]]; then @@ -674,7 +677,10 @@ songs () { elif [[ $val -eq 26 ]]; then mpc prev - POS=$(echo $(( $POS -1 ))) + mpd_play=$(mpc status | mpc status | grep -E '\[playing\]|\[paused\]') + if [[ -n ${mpd_play} ]]; then + POS=$(echo $(( $(mpc current -f '%position%') + 0 ))) + fi elif [[ $val -eq 27 ]]; then mpc stop @@ -724,6 +730,10 @@ songs () { elif [[ $val -eq 17 ]]; then unset last mpc toggle + mpd_play=$(mpc status | mpc status | grep -E '\[playing\]|\[paused\]') + if [[ -n ${mpd_play} ]]; then + POS=$(echo $(( $(mpc current -f '%position%') + 0 ))) + fi elif [[ $val -eq 18 ]]; then unset last |