blob: 89dba44cc194183b9bc743aeedaef8990cfea757 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
|
#!/usr/bin/env bash
STATUS=$(playerctl status)
case $STATUS in
"Playing")
TITLE=$(playerctl metadata title | sed s/_/\ /g)
META="${TITLE:-Title}"
curstatus=" 🎵 $META \uE0b1"
;;
"Paused")
TITLE=$(playerctl metadata title | sed s/.m4a//g)
META="${TITLE:-Title}"
curstatus=" || $META \uE0b1"
;;
*)
curstatus=" "
;;
esac
echo -e "$curstatus"
case "$BLOCK_BUTTON" in
1)
playerctl play-pause
;;
esac
exit 0
|