nixos-config/home-manager/modules/kanshi/default.nix

69 lines
1.4 KiB
Nix
Raw Normal View History

2024-08-28 16:55:22 +02:00
{
config,
lib,
...
}:
with lib;
let
cfg = config.eboskma.services.kanshi;
in
{
options.eboskma.services.kanshi = {
enable = mkEnableOption "kanshi";
};
config = mkIf cfg.enable {
services.kanshi = {
enable = true;
settings = [
{
profile = {
name = "local";
outputs = [
{
criteria = "DP-1";
status = "enable";
mode = "3840x2160@60Hz";
position = "0,0";
2024-08-28 16:55:22 +02:00
}
{
criteria = "DP-3";
status = "enable";
mode = "3840x2160@60Hz";
position = "3840,0";
2024-08-28 16:55:22 +02:00
}
{
criteria = "HDMI-A-1";
status = "disable";
}
];
};
}
{
profile = {
name = "remote";
outputs = [
{
criteria = "DP-1";
status = "disable";
}
{
criteria = "DP-3";
status = "disable";
}
{
criteria = "HDMI-A-1";
status = "enable";
mode = "1920x1080@120Hz";
position = "0,0";
2024-08-28 16:55:22 +02:00
}
];
};
}
];
};
home.packages = [ config.services.kanshi.package ];
};
}