adds playerctl support for spotifyd

This commit is contained in:
Moritz Böhme 2021-11-04 17:28:42 +01:00
parent d488882f45
commit cb33921e13
2 changed files with 4 additions and 3 deletions

View file

@ -5,6 +5,7 @@
home.packages = with pkgs; [ spotify-tui ];
services.spotifyd = {
enable = true;
package = pkgs.spotifyd.override { withMpris = true; };
settings = {
global = {
# A command that gets executed and can be used to

View file

@ -135,11 +135,11 @@ XF86AudioLowerVolume
XF86AudioMute
pamixer -t
XF86AudioPlay
playerctl -p "spotify,firefox" play-pause
[ $(playerctl -p "spotifyd,firefox" status) = "Playing" ] && playerctl -p "spotifyd,firefox" pause || playerctl -p "spotifyd,firefox" play
XF86AudioNext
playerctl -p "spotify,firefox" next
playerctl -p "spotify,spotifyd,firefox" next
XF86AudioPrev
playerctl -p "spotify,firefox" previous
playerctl -p "spotify,spotifyd,firefox" previous
XF86MonBrightnessDown
brightnessctl s 10%-