dotfiles/os/desktop/autorandr.nix

29 lines
469 B
Nix
Raw Permalink Normal View History

2024-12-15 00:29:51 +01:00
{
pkgs,
lib,
config,
...
}:
let
2024-12-15 00:29:51 +01:00
setupScript = "${
pkgs.writeShellApplication {
name = "greeter-setup-script";
runtimeInputs = [ pkgs.autorandr ];
text = ''
autorandr --change
'';
}
}/bin/greeter-setup-script";
in
{
config = {
services = {
autorandr.enable = true;
xserver.displayManager.lightdm.extraConfig = ''
[Seat:*]
display-setup-script = ${setupScript}
'';
};
};
}