aboutsummaryrefslogtreecommitdiff
path: root/.local/bin/tsarbar_status.sh
diff options
context:
space:
mode:
Diffstat (limited to '.local/bin/tsarbar_status.sh')
-rwxr-xr-x.local/bin/tsarbar_status.sh14
1 files changed, 8 insertions, 6 deletions
diff --git a/.local/bin/tsarbar_status.sh b/.local/bin/tsarbar_status.sh
index 1fdda43..3fe67fb 100755
--- a/.local/bin/tsarbar_status.sh
+++ b/.local/bin/tsarbar_status.sh
@@ -75,12 +75,14 @@ done &
playerctl -F metadata -f "{{lc(status)}} {{lc(title)}} - {{lc(artist)}}" \
| while read -r line; do
status=`echo $line | awk '{ print $1 }'`
- case "$status" in "paused")
- tsarc set player -text "no media"
- esac
- case "$status" in "playing")
- tsarc set player -text \
- "`echo $line | awk 'match($0, $1) {print substr($0, RSTART+RLENGTH)}' | trim`"
+ case "$status" in
+ "paused")
+ tsarc set player -text "no media"
+ ;;
+ "playing")
+ tsarc set player -text \
+ "`echo $line | awk 'match($0, $1) {print substr($0, RSTART+RLENGTH)}' | trim`"
+ ;;
esac
done &