zaphyra's git: nixfiles

zaphyra's nixfiles

1 
2 
3 
4 
5 
6 
7 
8 
9 
10 
11 
12 
13 
14 
15 
16 
17 
18 
19 
20 
21 
22 
23 
24 
{
  config,
  pkgs,
  lib,
  ...
}:

{

  services = {
    playerctld.enable = true;
    mpris-proxy.enable = true;
  };

  programs.niri.settings = with config.lib.niri.actions; {
    binds = {
      "XF86AudioPlay".action = spawn (lib.getExe pkgs.playerctl) "play-pause";
      "XF86AudioNext".action = spawn (lib.getExe pkgs.playerctl) "next";
      "XF86AudioPrev".action = spawn (lib.getExe pkgs.playerctl) "previous";
    };
    switch-events.lid-close.action = spawn (lib.getExe pkgs.playerctl) "--all-players" "pause";
  };

}