xmonad + xmobar - using mpd/ncmpcpp
This commit is contained in:
parent
f4d4b5b0cd
commit
67d5f6b40d
4 changed files with 15 additions and 16 deletions
10
config/xmobar/scripts/music
Executable file
10
config/xmobar/scripts/music
Executable file
|
@ -0,0 +1,10 @@
|
|||
#!/bin/bash
|
||||
|
||||
if mpc -q; then
|
||||
case "$(mpc status | sed -n '2s/\[\(\w*\)\].*/\1/p')" in
|
||||
"playing") icon="<icon=music/play.xpm/>" ;;
|
||||
"paused") icon="<icon=music/pause.xpm/>" ;;
|
||||
esac
|
||||
echo '<action=`urxvtc -e "ncmpcpp"`>'"$icon"'</action>'
|
||||
fi
|
||||
|
|
@ -1,11 +0,0 @@
|
|||
#!/bin/bash
|
||||
|
||||
status=$(quodlibet --status | cut -d' ' -f1)
|
||||
case "$status" in
|
||||
"playing") icon="<icon=music/play.xpm/>" ;;
|
||||
"paused") icon="<icon=music/pause.xpm/>" ;;
|
||||
*) ;;
|
||||
esac
|
||||
|
||||
echo '<action=`quodlibet --toggle-window`>'"$icon"'</action>'
|
||||
|
Loading…
Add table
Add a link
Reference in a new issue