2020-05-14 20:03:55 +02:00
|
|
|
#!/bin/sh
|
|
|
|
|
|
|
|
while (true); do
|
|
|
|
if [ "$(mpc | wc -l)" -eq "3" ]; then
|
2020-05-14 22:09:25 +02:00
|
|
|
SONG=$(mpc | head -1)" | "
|
2020-05-14 20:03:55 +02:00
|
|
|
if [ "$(mpc | grep '\[paused\]' | wc -l)" -eq "1" ]; then
|
|
|
|
SONG="⏸ $SONG"
|
|
|
|
fi
|
|
|
|
fi
|
|
|
|
|
2020-05-14 22:09:25 +02:00
|
|
|
xsetroot -name " $SONG$(date '+%Y-%m-%d %H:%M:%S') "
|
2020-05-14 20:03:55 +02:00
|
|
|
sleep 0.3s;
|
|
|
|
done
|