1 Commits
master ... niri

Author SHA1 Message Date
1d205d39c3 users/jordan: add niri config 2025-12-26 23:09:37 +00:00
5 changed files with 392 additions and 17 deletions

140
flake.lock generated
View File

@@ -517,11 +517,11 @@
]
},
"locked": {
"lastModified": 1766939458,
"narHash": "sha256-VvZeAKyB3vhyHStSO8ACKzWRKNQPmVWktjfuSVdvtUA=",
"lastModified": 1766553861,
"narHash": "sha256-ZbnG01yA3O8Yr1vUm3+NQ2qk9iRhS5bloAnuXHHy7+c=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "e298a148013c980e3c8c0ac075295fab5074d643",
"rev": "0999ed8f965bbbd991437ad9c5ed3434cecbc30e",
"type": "github"
},
"original": {
@@ -606,11 +606,11 @@
"xdph": "xdph"
},
"locked": {
"lastModified": 1766929444,
"narHash": "sha256-mGk+mk/miObjivy+6qMqQm+Jyl8R7t6B/1SaiBkUUyY=",
"lastModified": 1766761711,
"narHash": "sha256-m9VZ9cxYUl9Q9+ROSKmYpVeyIAvz1faqNqBKZ4WamWI=",
"owner": "hyprwm",
"repo": "Hyprland",
"rev": "6a055fc747a5a899b97f9b4c1d1a52229a805b1e",
"rev": "33df518f97b930316742736ecb07dc322da4c5d3",
"type": "github"
},
"original": {
@@ -939,6 +939,64 @@
"type": "github"
}
},
"niri": {
"inputs": {
"niri-stable": "niri-stable",
"niri-unstable": "niri-unstable",
"nixpkgs": [
"nixpkgs"
],
"nixpkgs-stable": "nixpkgs-stable",
"xwayland-satellite-stable": "xwayland-satellite-stable",
"xwayland-satellite-unstable": "xwayland-satellite-unstable"
},
"locked": {
"lastModified": 1766765523,
"narHash": "sha256-DCk3GKdKZNjpvNuDy9ZVfVwCy3tlm96/UZnYkJO7N44=",
"owner": "sodiboo",
"repo": "niri-flake",
"rev": "a3e638c75d07de759421e6f34bd69c3f9a0a3567",
"type": "github"
},
"original": {
"owner": "sodiboo",
"repo": "niri-flake",
"type": "github"
}
},
"niri-stable": {
"flake": false,
"locked": {
"lastModified": 1756556321,
"narHash": "sha256-RLD89dfjN0RVO86C/Mot0T7aduCygPGaYbog566F0Qo=",
"owner": "YaLTeR",
"repo": "niri",
"rev": "01be0e65f4eb91a9cd624ac0b76aaeab765c7294",
"type": "github"
},
"original": {
"owner": "YaLTeR",
"ref": "v25.08",
"repo": "niri",
"type": "github"
}
},
"niri-unstable": {
"flake": false,
"locked": {
"lastModified": 1766751930,
"narHash": "sha256-83/YSW6c58i/iwGzAFApuMy6MCgoIaROeCcoIGh+ViU=",
"owner": "YaLTeR",
"repo": "niri",
"rev": "b5640d5293ad8dca06cb447692ea7cbb21680eb1",
"type": "github"
},
"original": {
"owner": "YaLTeR",
"repo": "niri",
"type": "github"
}
},
"nix-topology": {
"inputs": {
"devshell": "devshell_3",
@@ -1034,13 +1092,29 @@
"type": "github"
}
},
"nixpkgs-unstable": {
"nixpkgs-stable": {
"locked": {
"lastModified": 1766902085,
"narHash": "sha256-coBu0ONtFzlwwVBzmjacUQwj3G+lybcZ1oeNSQkgC0M=",
"lastModified": 1766736597,
"narHash": "sha256-BASnpCLodmgiVn0M1MU2Pqyoz0aHwar/0qLkp7CjvSQ=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "c0b0e0fddf73fd517c3471e546c0df87a42d53f4",
"rev": "f560ccec6b1116b22e6ed15f4c510997d99d5852",
"type": "github"
},
"original": {
"owner": "NixOS",
"ref": "nixos-25.11",
"repo": "nixpkgs",
"type": "github"
}
},
"nixpkgs-unstable": {
"locked": {
"lastModified": 1766651565,
"narHash": "sha256-QEhk0eXgyIqTpJ/ehZKg9IKS7EtlWxF3N7DXy42zPfU=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "3e2499d5539c16d0d173ba53552a4ff8547f4539",
"type": "github"
},
"original": {
@@ -1051,11 +1125,11 @@
},
"nixpkgs_2": {
"locked": {
"lastModified": 1766885793,
"narHash": "sha256-P6RVkrM9JLCW6xBjSwHfgTOQ1JwBUma5xe5LI8xAPC0=",
"lastModified": 1766736597,
"narHash": "sha256-BASnpCLodmgiVn0M1MU2Pqyoz0aHwar/0qLkp7CjvSQ=",
"owner": "NixOS",
"repo": "nixpkgs",
"rev": "9ef261221d1e72399f2036786498d78c38185c46",
"rev": "f560ccec6b1116b22e6ed15f4c510997d99d5852",
"type": "github"
},
"original": {
@@ -1074,11 +1148,11 @@
"systems": "systems_6"
},
"locked": {
"lastModified": 1766849711,
"narHash": "sha256-gtLBwhgjERca1UCzGkFplD5epIVRiNkePHVVtyFr73g=",
"lastModified": 1766725080,
"narHash": "sha256-JG0KvKmVyAQZ4PxKVDy7FGGUirt1lLhWwGwy9ExLCoI=",
"owner": "nix-community",
"repo": "nixvim",
"rev": "cae79c48e93bd61e478dfc12456bf68b1ce66074",
"rev": "2d3184cd3dd31f6eb57eb4ddfe2387ebd141f1e5",
"type": "github"
},
"original": {
@@ -1171,6 +1245,7 @@
"hyprland-plugins": "hyprland-plugins",
"impermanence": "impermanence",
"kvlibadwaita": "kvlibadwaita",
"niri": "niri",
"nix-topology": "nix-topology",
"nixos-hardware": "nixos-hardware",
"nixos-mailserver": "nixos-mailserver",
@@ -1404,6 +1479,39 @@
"repo": "xdg-desktop-portal-hyprland",
"type": "github"
}
},
"xwayland-satellite-stable": {
"flake": false,
"locked": {
"lastModified": 1755491097,
"narHash": "sha256-m+9tUfsmBeF2Gn4HWa6vSITZ4Gz1eA1F5Kh62B0N4oE=",
"owner": "Supreeeme",
"repo": "xwayland-satellite",
"rev": "388d291e82ffbc73be18169d39470f340707edaa",
"type": "github"
},
"original": {
"owner": "Supreeeme",
"ref": "v0.7",
"repo": "xwayland-satellite",
"type": "github"
}
},
"xwayland-satellite-unstable": {
"flake": false,
"locked": {
"lastModified": 1766429945,
"narHash": "sha256-9Kv4gWagx/u4RfZJzBMAoagW9ava5waxd+XoTkzqF7E=",
"owner": "Supreeeme",
"repo": "xwayland-satellite",
"rev": "0dde7ca1d3a8e8c5082533d76084e2aa02bef70e",
"type": "github"
},
"original": {
"owner": "Supreeeme",
"repo": "xwayland-satellite",
"type": "github"
}
}
},
"root": "root",

View File

@@ -62,6 +62,11 @@
nixos-hardware.url = "github:NixOS/nixos-hardware";
niri = {
url = "github:sodiboo/niri-flake";
inputs.nixpkgs.follows = "nixpkgs";
};
nixos-mailserver = {
url = "gitlab:simple-nixos-mailserver/nixos-mailserver/nixos-25.11";
inputs.nixpkgs.follows = "nixpkgs";

View File

@@ -24,6 +24,7 @@
config.allowUnfree = true;
overlays = [
inputs.agenix.overlays.default
inputs.niri.overlays.niri
(final: prev: {
unstable = import inputs.nixpkgs-unstable {
config = {

View File

@@ -0,0 +1,261 @@
{
config,
lib,
inputs,
pkgs,
...
}:
let
inherit (lib)
getExe
;
in
{
imports = [
inputs.niri.homeModules.niri
];
xdg.portal = {
enable = true;
xdgOpenUsePortal = true;
config.niri = {
default = [
"gnome"
"gtk"
];
"org.freedesktop.impl.portal.Access" = "gtk";
"org.freedesktop.impl.portal.Notification" = "gtk";
"org.freedesktop.impl.portal.Secret" = "gnome-keyring";
"org.freedesktop.impl.portal.FileChooser" = "gtk";
"org.freedesktop.impl.portal.ScreenCast" = [ "gnome" ];
"org.freedesktop.impl.portal.Screenshot" = [ "gnome" ];
};
extraPortals = with pkgs; [
xdg-desktop-portal-gtk
xdg-desktop-portal-gnome
];
};
programs.niri = {
enable = true;
package = pkgs.niri-unstable;
settings = {
xwayland-satellite.path = getExe pkgs.xwayland-satellite-stable;
input = {
keyboard = {
xkb = {
layout = "us";
variant = "intl";
};
repeat-delay = 235;
repeat-rate = 60;
};
touchpad = {
tap = true;
dwt = true;
dwtp = true;
natural-scroll = true;
accel-profile = "flat";
};
mouse = {
accel-speed = 0.2;
accel-profile = "flat";
};
power-key-handling.enable = false;
workspace-auto-back-and-forth = true;
};
gestures.hot-corners.enable = false;
debug.honor-xdg-activation-with-invalid-serial = true;
binds = with config.lib.niri.actions; {
"Mod+T".action = spawn "kitty";
"Mod+b".action = spawn "firefox";
"Super+Alt+L".action = spawn "systemctl suspend";
XF86AudioRaiseVolume = {
action = spawn "wpctl" "set-volume" "@DEFAULT_AUDIO_SINK@" "0.1+";
allow-when-locked = true;
};
XF86AudioLowerVolume = {
action = spawn "wpctl" "set-volume" "@DEFAULT_AUDIO_SINK@" "0.1-";
allow-when-locked = true;
};
XF86AudioMute = {
action = spawn "wpctl" "set-mute" "@DEFAULT_AUDIO_SINK@" "toggle";
allow-when-locked = true;
};
XF86AudioMicMute = {
action = spawn "wpctl" "set-mute" "@DEFAULT_AUDIO_SOURCE@" "toggle";
allow-when-locked = true;
};
"Mod+Q".action = close-window;
"Mod+n".action = focus-column-left;
"Mod+left".action = focus-column-left;
"Mod+Shift+n".action = move-column-left;
"Mod+Shift+left".action = move-column-left;
"Mod+r".action = focus-window-or-workspace-down;
"Mod+down".action = focus-window-or-workspace-down;
"Mod+Shift+r".action = move-window-down;
"Mod+Shift+down".action = move-window-down;
"Mod+l".action = focus-window-or-workspace-up;
"Mod+up".action = focus-window-or-workspace-up;
"Mod+Shift+l".action = move-window-up;
"Mod+Shift+up".action = move-window-up;
"Mod+s".action = focus-column-right;
"Mod+right".action = focus-column-right;
"Mod+Shift+s".action = move-column-right;
"Mod+Shift+right".action = move-column-right;
"Mod+h".action = focus-column-first;
"Mod+Shift+h".action = consume-or-expel-window-left;
"Mod+m".action = focus-column-last;
"Mod+Shift+m".action = consume-or-expel-window-right;
"Mod+Ctrl+n".action = focus-monitor-left;
"Mod+Shift+Ctrl+n".action = move-column-to-monitor-left;
"Mod+Ctrl+r".action = focus-monitor-down;
"Mod+Shift+Ctrl+r".action = move-column-to-monitor-down;
"Mod+Ctrl+l".action = focus-monitor-up;
"Mod+Shift+Ctrl+l".action = move-column-to-monitor-up;
"Mod+Ctrl+s".action = focus-monitor-right;
"Mod+Shift+Ctrl+s".action = move-column-to-monitor-right;
"Mod+Period".action = focus-workspace-down;
"Mod+Shift+Period".action = move-column-to-workspace-down;
"Mod+Ctrl+Period".action = move-workspace-down;
"Mod+comma".action = focus-workspace-up;
"Mod+Shift+comma".action = move-column-to-workspace-up;
"Mod+Ctrl+comma".action = move-workspace-up;
"Mod+WheelScrollDown" = {
action = focus-workspace-down;
cooldown-ms = 150;
};
"Mod+WheelScrollUp" = {
action = focus-workspace-up;
cooldown-ms = 150;
};
"Mod+Ctrl+WheelScrollDown" = {
action = move-column-to-workspace-down;
cooldown-ms = 150;
};
"Mod+Ctrl+WheelScrollUp" = {
action = move-column-to-workspace-up;
cooldown-ms = 150;
};
"Mod+WheelScrollRight".action = focus-column-right;
"Mod+WheelScrollLeft".action = focus-column-left;
"Mod+Ctrl+WheelScrollRight".action = move-column-right;
"Mod+Ctrl+WheelScrollLeft".action = move-column-left;
"Mod+Shift+WheelScrollDown".action = focus-column-right;
"Mod+Shift+WheelScrollUp".action = focus-column-left;
"Mod+Ctrl+Shift+WheelScrollDown".action = move-column-right;
"Mod+Ctrl+Shift+WheelScrollUp".action = move-column-left;
"Mod+V".action = maximize-column;
"Mod+Ctrl+V".action = expand-column-to-available-width;
"Mod+return".action = fullscreen-window;
"Mod+Minus".action = set-column-width "-10%";
"Mod+Shift+0".action = set-column-width "+10%";
"Mod+F".action = toggle-window-floating;
"Mod+Ctrl+F".action = switch-focus-between-floating-and-tiling;
"Mod+y".action = toggle-column-tabbed-display;
#"Print".action = screenshot;
#"Ctrl+Print".action = screenshot-screen {};
#"Alt+Print".action = screenshot-window;
"Mod+Escape" = {
action = toggle-keyboard-shortcuts-inhibit;
allow-inhibiting = false;
};
# The quit action will show a confirmation dialog to avoid accidental exits.
"Mod+Ctrl+Escape".action = quit;
# Powers off the monitors. To turn them back on, do any input like
# moving the mouse or pressing any other key.
"Mod+Shift+P".action = power-off-monitors;
};
spawn-at-startup = [
{ command = [ "firefox" ]; }
];
prefer-no-csd = true;
hotkey-overlay = {
skip-at-startup = true;
};
layout = {
gaps = 1;
center-focused-column = "never";
empty-workspace-above-first = true;
preset-column-widths = [
{ proportion = 0.33333; }
{ proportion = 0.5; }
{ proportion = 0.66667; }
];
default-column-width = {
proportion = 0.5;
};
preset-window-heights = [
{ proportion = 0.33333; }
{ proportion = 0.5; }
{ proportion = 0.66667; }
];
focus-ring = {
enable = true;
width = 2;
active.color = "#7fc8ff";
inactive.color = "#505050";
};
border = {
enable = false;
width = 2;
active.color = "#ffc87f";
inactive.color = "#505050";
};
shadow = {
# on
softness = 30;
spread = 5;
offset = {
x = 0;
y = 5;
};
draw-behind-window = true;
color = "#00000070";
# inactive-color "#00000054"
};
tab-indicator = {
# off
hide-when-single-tab = true;
place-within-column = true;
gap = 5;
width = 4;
length = {
total-proportion = 1.0;
};
position = "right";
gaps-between-tabs = 2;
corner-radius = 8;
active.color = "red";
inactive.color = "gray";
};
insert-hint = {
# off
display.color = "#ffc87f80";
};
};
};
};
}

View File

@@ -7,7 +7,7 @@
imports = [
./common/optional/graphical/firefox.nix
./common/optional/graphical/fonts.nix
./common/optional/graphical/hyprland
./common/optional/graphical/niri.nix
./common/optional/graphical/mimeapps.nix
];