diff options
Diffstat (limited to 'cmus-status')
| -rwxr-xr-x | cmus-status | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/cmus-status b/cmus-status new file mode 100755 index 0000000..0afbc47 --- /dev/null +++ b/cmus-status @@ -0,0 +1,19 @@ +#!/bin/sh +# :set status_display_program=cmus-status +# copy this program to one of the $PATH +file="/tmp/cmus-status" +printf "" > $file # refresh +[ $# = 2 ] &&\ + printf "" > $file &&\ + exit 0 +if [ "$2" = "playing" ]; +then s=""; +else s=""; +fi +artist="${6}" +album="${10}" +num="${14}." +title="${16}" +format="$s $artist - $num $title" +notify-send "🎵 Player" "$album\n$format" -t 3000 +printf "%s" "$format" >> $file |