Modify music player scripts to use spotifyd
This commit is contained in:
parent
0e831ebd9f
commit
82669efb95
@ -1,7 +1,7 @@
|
|||||||
super + Return
|
super + Return
|
||||||
$($TERMINAL)
|
$($TERMINAL)
|
||||||
super + {_,ctrl,alt +} b
|
super + {_,ctrl,alt +} b
|
||||||
{search,firefox,tor-browser}
|
{search,chromium,tor-browser}
|
||||||
super + {_,shift +} d
|
super + {_,shift +} d
|
||||||
rofi -show {run,drun}
|
rofi -show {run,drun}
|
||||||
super + shift + s
|
super + shift + s
|
||||||
@ -54,15 +54,15 @@ XF86Audio{Raise,Lower}Volume
|
|||||||
amixer sset Master 5%{+,-} && refbar
|
amixer sset Master 5%{+,-} && refbar
|
||||||
# songs control
|
# songs control
|
||||||
XF86Audio{Next,Prev}
|
XF86Audio{Next,Prev}
|
||||||
mpc {next,prev} && refbar
|
playerctl {next,previous} && refbar
|
||||||
ctrl + XF86Audio{Next,Prev}
|
ctrl + XF86Audio{Next,Prev}
|
||||||
mpc seek {+,-}4
|
mpc seek {+,-}4
|
||||||
# pause/play
|
# pause/play
|
||||||
{XF86AudioPlay,super + slash}
|
{XF86AudioPlay,super + slash}
|
||||||
mpc toggle && refbar
|
playerctl play-pause && refbar
|
||||||
# stop
|
# stop
|
||||||
XF86AudioStop
|
XF86AudioStop
|
||||||
mpc stop && refbar
|
playerctl stop && refbar
|
||||||
|
|
||||||
ctrl + alt + {Left,Up,Down,Right}
|
ctrl + alt + {Left,Up,Down,Right}
|
||||||
rotscreen {left,normal,inverted,right}
|
rotscreen {left,normal,inverted,right}
|
||||||
|
@ -1,11 +1,23 @@
|
|||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
|
|
||||||
echo ""
|
if playerctl metadata --format={{playerName}} | grep -q "spotifyd"; then
|
||||||
if mpc status | grep -q "playing"; then
|
echo ""
|
||||||
mpc | sed "/^volume:/d;s/\\&/&/g;s/\\[playing\\].*//g"
|
else
|
||||||
elif mpc status | grep -q "paused"; then
|
echo ""
|
||||||
|
fi
|
||||||
|
|
||||||
|
# if mpc status | grep -q "playing"; then
|
||||||
|
# mpc | sed "/^volume:/d;s/\\&/&/g;s/\\[playing\\].*//g"
|
||||||
|
# elif mpc status | grep -q "paused"; then
|
||||||
|
# echo ""
|
||||||
|
# else
|
||||||
|
# echo ""
|
||||||
|
# fi
|
||||||
|
|
||||||
|
if playerctl --player=spotifyd status | grep -q "Playing"; then
|
||||||
|
playerctl metadata --format "{{ artist }} - {{ title }}"
|
||||||
|
elif playerctl --player=spotifyd status | grep -q "Paused"; then
|
||||||
echo ""
|
echo ""
|
||||||
else
|
else
|
||||||
echo ""
|
echo ""
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user