add now-playing script

This commit is contained in:
Inhji 2023-10-20 13:15:49 +02:00
parent bc30240aaa
commit 73d592ed7a
1 changed files with 8 additions and 0 deletions

8
config/scripts/now-playing.sh Executable file
View File

@ -0,0 +1,8 @@
#!/usr/bin/env bash
TITLE=$(cmus-remote -Q | grep title | cut --delimiter=' ' --fields=3-)
ARTIST=$(cmus-remote -Q | grep ' artist ' | cut --delimiter=' ' --fields=3-)
if [ -n "$ARTIST" ] || [ -n "$TITLE" ] ; then
echo "$ARTIST - $TITLE"
fi