feature(niri): use home-managers new niri-module to configure niri on my machines with host-specific additions
This commit is contained in:
@@ -26,6 +26,9 @@
|
||||
../../modules/nixos/vial.nix
|
||||
];
|
||||
|
||||
# host-specific niri config (outputs, input devices)
|
||||
home-manager.users.aaron.imports = [ ./niri.nix ];
|
||||
|
||||
# set hostname
|
||||
networking.hostName = "argon";
|
||||
|
||||
|
||||
@@ -0,0 +1,36 @@
|
||||
# argon: desktop with two 1440p monitors side by side
|
||||
{
|
||||
wayland.windowManager.niri.settings = {
|
||||
input = {
|
||||
touchpad.off = { };
|
||||
trackpoint.off = { };
|
||||
};
|
||||
|
||||
_children = [
|
||||
{
|
||||
output = {
|
||||
_args = [ "DP-1" ];
|
||||
mode = "2560x1440@165.000";
|
||||
scale = 1;
|
||||
transform = "normal";
|
||||
position._props = {
|
||||
x = 0;
|
||||
y = 0;
|
||||
};
|
||||
};
|
||||
}
|
||||
{
|
||||
output = {
|
||||
_args = [ "DP-2" ];
|
||||
mode = "2560x1440@143.912";
|
||||
scale = 1;
|
||||
transform = "normal";
|
||||
position._props = {
|
||||
x = 2560;
|
||||
y = 0;
|
||||
};
|
||||
};
|
||||
}
|
||||
];
|
||||
};
|
||||
}
|
||||
@@ -23,6 +23,9 @@
|
||||
../../modules/nixos/vial.nix
|
||||
];
|
||||
|
||||
# host-specific niri config (input devices, laptop binds)
|
||||
home-manager.users.aaron.imports = [ ./niri.nix ];
|
||||
|
||||
# set hostname
|
||||
networking.hostName = "neon";
|
||||
|
||||
|
||||
@@ -0,0 +1,34 @@
|
||||
# neon: laptop, built-in display is auto-configured by niri
|
||||
{ lib, ... }:
|
||||
|
||||
let
|
||||
brightness = step: {
|
||||
_props.allow-when-locked = true;
|
||||
spawn = [
|
||||
"brightnessctl"
|
||||
"--class=backlight"
|
||||
"set"
|
||||
step
|
||||
];
|
||||
};
|
||||
in
|
||||
{
|
||||
wayland.windowManager.niri.settings = {
|
||||
input.touchpad = {
|
||||
tap = { };
|
||||
natural-scroll = { };
|
||||
};
|
||||
|
||||
layout.gaps = lib.mkForce 10;
|
||||
|
||||
binds = {
|
||||
"Print".screenshot = { };
|
||||
"Ctrl+Print".screenshot-screen = { };
|
||||
"Mod+Shift+P".power-off-monitors = { };
|
||||
|
||||
# finer brightness steps; mkForce, since spawn lists would otherwise be concatenated
|
||||
"XF86MonBrightnessUp" = lib.mkForce (brightness "+1%");
|
||||
"XF86MonBrightnessDown" = lib.mkForce (brightness "1%-");
|
||||
};
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user