diff --git a/flake.lock b/flake.lock index 3b7d2c6..7b6bf8b 100644 --- a/flake.lock +++ b/flake.lock @@ -84,6 +84,22 @@ "type": "github" } }, + "base16-schemes": { + "flake": false, + "locked": { + "lastModified": 1696158499, + "narHash": "sha256-5yIHgDTPjoX/3oDEfLSQ0eJZdFL1SaCfb9d6M0RmOTM=", + "owner": "tinted-theming", + "repo": "base16-schemes", + "rev": "a9112eaae86d9dd8ee6bb9445b664fba2f94037a", + "type": "github" + }, + "original": { + "owner": "tinted-theming", + "repo": "base16-schemes", + "type": "github" + } + }, "base16-vim": { "flake": false, "locked": { @@ -104,11 +120,11 @@ "cachyos-kernel": { "flake": false, "locked": { - "lastModified": 1779085181, - "narHash": "sha256-ZdiBlGOkI9tS3ggyNlJ5gU4qCkvGWLT3sbrnHEemN2o=", + "lastModified": 1779781360, + "narHash": "sha256-02SR7VL4wc57NCVMhyVgz6/SVfyGv7mc4h+SmgR2I8g=", "owner": "CachyOS", "repo": "linux-cachyos", - "rev": "391e1e35d62d30dccd14ec3af01d58e5310b7d80", + "rev": "c7cb822e8ee91d993052becf2661b6f26f98eaa2", "type": "github" }, "original": { @@ -120,11 +136,11 @@ "cachyos-kernel-patches": { "flake": false, "locked": { - "lastModified": 1779191960, - "narHash": "sha256-QqEC7SVMVf1vj9OoflWzP+nGewMrUNSBSf1dB8sUbqY=", + "lastModified": 1779618819, + "narHash": "sha256-/cGZZCyJZS1QATHi+/2Q32NkjrYN2N2PpgFP8Ak4FJc=", "owner": "CachyOS", "repo": "kernel-patches", - "rev": "65cbbfc17bb7e172cb06ef69037be5b0d517b2cd", + "rev": "668b466fb461409329425b50c4a9d8d2c022a739", "type": "github" }, "original": { @@ -133,6 +149,22 @@ "type": "github" } }, + "catppuccin-userstyles": { + "flake": false, + "locked": { + "lastModified": 1779280428, + "narHash": "sha256-kcssEdPAW27y7UN3x1Go7l6GDcpqoVmO0qEG085rPyg=", + "owner": "catppuccin", + "repo": "userstyles", + "rev": "bad308b8d0b3eb6cdbb975dbe99ecd5ec9f479be", + "type": "github" + }, + "original": { + "owner": "catppuccin", + "repo": "userstyles", + "type": "github" + } + }, "crane": { "locked": { "lastModified": 1765145449, @@ -220,6 +252,22 @@ "url": "https://install.determinate.systems/determinate-nixd/tag/v3.21.0/x86_64-linux" } }, + "discord-userstyle": { + "flake": false, + "locked": { + "lastModified": 1770426312, + "narHash": "sha256-rxvHIifq5CYIBPwFA2SpOrWT+sG/z0ItXT3sx2wbEqg=", + "owner": "catppuccin", + "repo": "discord", + "rev": "b9b5547f0b32296d2389716ef606de87b3c1e7c7", + "type": "github" + }, + "original": { + "owner": "catppuccin", + "repo": "discord", + "type": "github" + } + }, "disko": { "inputs": { "nixpkgs": [ @@ -264,11 +312,11 @@ "firefox-gnome-theme": { "flake": false, "locked": { - "lastModified": 1776136500, - "narHash": "sha256-r0gN2brVWA351zwMV0Flmlcd6SGMvYqFbvC3DfKFM8Y=", + "lastModified": 1779670703, + "narHash": "sha256-UdfMivNMwCCqQsYDg5pSz8X2IOaOrIZLIIy+Bg3CO2o=", "owner": "rafaelmardojai", "repo": "firefox-gnome-theme", - "rev": "0f8ba203d475587f477e7ae12661bd8459e225b7", + "rev": "942159e73e40bf785816f7f1f5feed9ef3d7c8f9", "type": "github" }, "original": { @@ -571,11 +619,11 @@ ] }, "locked": { - "lastModified": 1779507042, - "narHash": "sha256-7wOwi8B6D0BYsieZCnHZZj2sNUzgJhLoIVSfkwB7lxQ=", + "lastModified": 1779969295, + "narHash": "sha256-HwIJ3tOcwSMiV75L7KqJXciXR9UfT+d7rwOZMX7cTnA=", "owner": "nix-community", "repo": "home-manager", - "rev": "509ed3c603349a9d43de9e2ae6613baea6bd5b34", + "rev": "61e2c9659324181e0f0ed911958c536333b1d4f6", "type": "github" }, "original": { @@ -1001,11 +1049,11 @@ }, "locked": { "dir": "packages/nix", - "lastModified": 1778870989, - "narHash": "sha256-0GHc0BjLwPIqJxlD8SrG2baM1nXdIt/yc8UbQvyh/Go=", + "lastModified": 1779813116, + "narHash": "sha256-38Bm3h1l5LMPZUhviiK8eg7PoTeckxv3uQmFCWEXid4=", "owner": "SteamClientHomebrew", "repo": "Millennium", - "rev": "b59659da33ee5094cdbff6adb0b71c25bbb335ed", + "rev": "e2997de8fa6f5fab2e72c456b74a83fd01035ff1", "type": "github" }, "original": { @@ -1099,11 +1147,11 @@ "nixpkgs": "nixpkgs_4" }, "locked": { - "lastModified": 1779477384, - "narHash": "sha256-lByanSWg/pKyDJ2pMuphIxMuCMy7qpYG2/gGjp//UFk=", + "lastModified": 1779910731, + "narHash": "sha256-BSu/X9EyAyAPOjXsuwED4j4IeduP/5KVjTwiQSLkdik=", "owner": "xddxdd", "repo": "nix-cachyos-kernel", - "rev": "86d7051a5694db99f4db6165bcaf15e7bba8672a", + "rev": "a2cdbecf6abb1a1180bf9fe5c3028125416621f1", "type": "github" }, "original": { @@ -1113,6 +1161,28 @@ "type": "github" } }, + "nix-colors": { + "inputs": { + "base16-schemes": "base16-schemes", + "nixpkgs-lib": [ + "nix-userstyles", + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1707825078, + "narHash": "sha256-hTfge2J2W+42SZ7VHXkf4kjU+qzFqPeC9k66jAUBMHk=", + "owner": "misterio77", + "repo": "nix-colors", + "rev": "b01f024090d2c4fc3152cd0cf12027a7b8453ba1", + "type": "github" + }, + "original": { + "owner": "misterio77", + "repo": "nix-colors", + "type": "github" + } + }, "nix-flatpak": { "locked": { "lastModified": 1777402031, @@ -1135,11 +1205,11 @@ ] }, "locked": { - "lastModified": 1778999127, - "narHash": "sha256-V5GquqJvAqwFTcpN6hxKSQAtwuJFRUEHmyNKbeaTQDg=", + "lastModified": 1779604987, + "narHash": "sha256-ZQ5z+fVhxYKtIFwtqGp5O0PD84BM1riASvqDaN5Xs+s=", "owner": "nix-community", "repo": "nix-index-database", - "rev": "f680e0d3c1dbefe298c423691662e238496890f2", + "rev": "8fba98c80b48fa013820e0163c5096922fea4ddd", "type": "github" }, "original": { @@ -1148,6 +1218,39 @@ "type": "github" } }, + "nix-userstyles": { + "inputs": { + "catppuccin-userstyles": "catppuccin-userstyles", + "discord-userstyle": "discord-userstyle", + "flake-parts": [ + "flake-parts" + ], + "import-tree": [ + "import-tree" + ], + "nix-colors": "nix-colors", + "nixpkgs": [ + "nixpkgs" + ], + "systems": "systems_2", + "treefmt-nix": [ + "treefmt-nix" + ] + }, + "locked": { + "lastModified": 1779411351, + "narHash": "sha256-tuh0vGXIcy979ShvcS3UyjGFNqv+Nw4jWtrGOXhRhHI=", + "owner": "adam01110", + "repo": "nix-userstyles", + "rev": "531a80f79c7b80c28a21a14a5b89e1e41a7ed398", + "type": "github" + }, + "original": { + "owner": "adam01110", + "repo": "nix-userstyles", + "type": "github" + } + }, "nixcord": { "inputs": { "flake-compat": "flake-compat_5", @@ -1158,11 +1261,11 @@ "nixpkgs-nixcord": "nixpkgs-nixcord" }, "locked": { - "lastModified": 1779498537, - "narHash": "sha256-6LQjFDS69JufrN4sVsMNsXxeSF6BbDzMSbN7sVApsaA=", + "lastModified": 1779960693, + "narHash": "sha256-TrkVXjb2vuSOiFyMipwlQAST+K+GsN89CtpUBK+IOm4=", "owner": "kaylorben", "repo": "nixcord", - "rev": "45a98c17b0d9e695bdee92ab00c76657eddf47e7", + "rev": "491f8c5e86a3aafe431398875b6755f7cb4ca5ee", "type": "github" }, "original": { @@ -1306,11 +1409,11 @@ }, "nixpkgs_4": { "locked": { - "lastModified": 1779436535, - "narHash": "sha256-jJ8YPw+bnLy1c8oI0hO4NKvbCQOt9V1aSUzhpLPs3Cw=", + "lastModified": 1779894193, + "narHash": "sha256-2PixoQSj9hdtoXTu0ZxdI0cmAE6GUUjCODG+rtC1wDc=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "d04de155b837ea2ba199ec83851b9dbffe57af08", + "rev": "a09ffe51cfdc37950f14286593605ce64f76cc93", "type": "github" }, "original": { @@ -1338,11 +1441,11 @@ }, "nixpkgs_6": { "locked": { - "lastModified": 1779475168, - "narHash": "sha256-5kB9V6f63Htxk/O8vzfXXw/mOCrR6F75GO7fJvQ9pJA=", - "rev": "a0991c886dc83e6e9de01d5266e4842985b1850e", + "lastModified": 1779877693, + "narHash": "sha256-24YGUZ9p3uLeDBGS5Nc8V7Rt5PaRg1vZ+rnfSuBW7hM=", + "rev": "4100e830e085863741bc69b156ec4ccd53ab5be0", "type": "tarball", - "url": "https://releases.nixos.org/nixpkgs/nixpkgs-26.05pre1003446.a0991c886dc8/nixexprs.tar.xz" + "url": "https://releases.nixos.org/nixpkgs/nixpkgs-26.11pre1006043.4100e830e085/nixexprs.tar.xz" }, "original": { "type": "tarball", @@ -1378,15 +1481,15 @@ "nixpkgs": [ "nixpkgs" ], - "systems": "systems_2", + "systems": "systems_3", "treefmt-nix": "treefmt-nix" }, "locked": { - "lastModified": 1778983195, - "narHash": "sha256-hE3EFK5GoSdbO5WHZ8bZDUVYkofbDLQN/KK25z7IOOI=", + "lastModified": 1779588472, + "narHash": "sha256-CVonDVo41DqdqS/kNeXFatwEuTltyXcppm9zkVOnrsM=", "owner": "noctalia-dev", "repo": "noctalia-qs", - "rev": "4116b41cdc89e186be7cb8b24a9b6022af95d742", + "rev": "70fea8a39a908e395de63024a4dfdb829bff1ffe", "type": "github" }, "original": { @@ -1405,11 +1508,11 @@ ] }, "locked": { - "lastModified": 1779551213, - "narHash": "sha256-CBWXFb//njiA2vB5CFuknX6HVhPGKMxLQ2w9K1fWQsI=", + "lastModified": 1779982645, + "narHash": "sha256-lY+CoGk/GUiXa0f9juTgrG4Ib4VNzFKc/dxjPgP6P3s=", "owner": "nix-community", "repo": "NUR", - "rev": "7f189705ebb1497af89b57c479f602fa69501f95", + "rev": "9cd3d768ff6322cb1657dc698715dd048b027be8", "type": "github" }, "original": { @@ -1429,7 +1532,7 @@ "nixpkgs": [ "nixpkgs" ], - "systems": "systems_3" + "systems": "systems_4" }, "locked": { "lastModified": 1779458887, @@ -1457,7 +1560,7 @@ "nixpkgs": [ "nixpkgs" ], - "systems": "systems_4", + "systems": "systems_5", "treefmt-nix": [ "treefmt-nix" ] @@ -1539,6 +1642,7 @@ "nix-cachyos-kernel": "nix-cachyos-kernel", "nix-flatpak": "nix-flatpak", "nix-index-database": "nix-index-database", + "nix-userstyles": "nix-userstyles", "nixcord": "nixcord", "nixhypr": "nixhypr", "nixpkgs": "nixpkgs_6", @@ -1639,14 +1743,14 @@ "nixpkgs": [ "nixpkgs" ], - "systems": "systems_5" + "systems": "systems_6" }, "locked": { - "lastModified": 1779000518, - "narHash": "sha256-wdtytSnzMe85J/qeXJALMzSLRFTZ1gBHwn81l1PtT8k=", + "lastModified": 1779824049, + "narHash": "sha256-dWHVUjP03KSVG1PaLKA6j9EdxWSxSQvipMUIcSyuA/U=", "owner": "Gerg-L", "repo": "spicetify-nix", - "rev": "5dde76b38418892ccb3d99e99bed7f8a43ac294c", + "rev": "1362178e5f5f7a848c49fe9dee004ef8824f100a", "type": "github" }, "original": { @@ -1672,18 +1776,18 @@ "nur": [ "nur" ], - "systems": "systems_6", + "systems": "systems_7", "tinted-kitty": "tinted-kitty", "tinted-schemes": "tinted-schemes", "tinted-tmux": "tinted-tmux", "tinted-zed": "tinted-zed" }, "locked": { - "lastModified": 1779378391, - "narHash": "sha256-IsDb9erotvx9npI94UDosvMeYQK17p7/vmU2v9batrY=", + "lastModified": 1779835981, + "narHash": "sha256-3VQklog/kSD9dw6uj6ElSfq3qwEHQWHCThR/cGcJ5Dc=", "owner": "danth", "repo": "stylix", - "rev": "c1456cc4ba3c9485e7b4158c909eeca5a752cd59", + "rev": "d7ba76c960a84333a7a1fc62ccf84a266086903a", "type": "github" }, "original": { @@ -1708,6 +1812,21 @@ } }, "systems_2": { + "locked": { + "lastModified": 1681028828, + "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", + "owner": "nix-systems", + "repo": "default", + "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", + "type": "github" + }, + "original": { + "owner": "nix-systems", + "repo": "default", + "type": "github" + } + }, + "systems_3": { "locked": { "lastModified": 1689347949, "narHash": "sha256-12tWmuL2zgBgZkdoB6qXZsgJEH9LR3oUgpaQq2RbI80=", @@ -1722,7 +1841,7 @@ "type": "github" } }, - "systems_3": { + "systems_4": { "locked": { "lastModified": 1681028828, "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", @@ -1737,7 +1856,7 @@ "type": "github" } }, - "systems_4": { + "systems_5": { "locked": { "lastModified": 1681028828, "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", @@ -1752,7 +1871,7 @@ "type": "github" } }, - "systems_5": { + "systems_6": { "locked": { "lastModified": 1681028828, "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", @@ -1767,7 +1886,7 @@ "type": "github" } }, - "systems_6": { + "systems_7": { "locked": { "lastModified": 1681028828, "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", @@ -1801,11 +1920,11 @@ "tinted-schemes": { "flake": false, "locked": { - "lastModified": 1777041405, - "narHash": "sha256-BAGZ7ObFV/9Z61OJZun7ifPyhkuHqNuW1QIhQ8LuzCo=", + "lastModified": 1777806186, + "narHash": "sha256-PDF0/wObw4nIsSBeXVYLsloXOiphXCgIdsrNcVXguKs=", "owner": "tinted-theming", "repo": "schemes", - "rev": "5f868b3a338b6904c47f3833b9c411be641983a8", + "rev": "0c94645546f4f3ddac77a1a5fce54eb95bf50795", "type": "github" }, "original": { @@ -1817,11 +1936,11 @@ "tinted-tmux": { "flake": false, "locked": { - "lastModified": 1777169200, - "narHash": "sha256-h7dDbIzP5hDr9v97w9PL6jdAgXawmj6krcH+959rqpU=", + "lastModified": 1778379944, + "narHash": "sha256-wPDFzMGSlARlw0Sfsn48Q2+jPSfk6N0Ng6BC/d+7Q24=", "owner": "tinted-theming", "repo": "tinted-tmux", - "rev": "f798c2dce44ef815bb6b8f05a82135c7942d35ac", + "rev": "fe0203a198690e71a5ff11e08812a4673de3678d", "type": "github" }, "original": { @@ -1833,11 +1952,11 @@ "tinted-zed": { "flake": false, "locked": { - "lastModified": 1777463218, - "narHash": "sha256-Bhkozqtq3BKLqWTlmKm8uAptfX4aRGI8QX3eEL54Vpc=", + "lastModified": 1778378178, + "narHash": "sha256-OXPXRIQgGwV77HjYRryOHguh4ALX96jkg+tseLkGgHA=", "owner": "tinted-theming", "repo": "base16-zed", - "rev": "5768d08ed2e7944a26a958868cdb073cb8856dae", + "rev": "9cd816033ff969415b190722cddf134e78a5665f", "type": "github" }, "original": { @@ -1960,11 +2079,11 @@ ] }, "locked": { - "lastModified": 1779455631, - "narHash": "sha256-svU6Ro4xiMxMA1KJGwQ/nfKwz3yXE/SONCw2Z1qTXHA=", + "lastModified": 1779918916, + "narHash": "sha256-hBmE9YbItnP1KTZGRkbpogoBWvtiY13uFOYYKdTV3ww=", "owner": "0xc000022070", "repo": "zen-browser-flake", - "rev": "5bcdfcef664bf62831dcb4b947004d9c5fbf7201", + "rev": "11d313b4ae461745f10f1050d296583dd82135c3", "type": "github" }, "original": { diff --git a/flake.nix b/flake.nix index 3bb931f..cb2dbc7 100644 --- a/flake.nix +++ b/flake.nix @@ -46,6 +46,15 @@ url = "github:nix-community/nix-index-database"; inputs.nixpkgs.follows = "nixpkgs"; }; + nix-userstyles = { + url = "github:adam01110/nix-userstyles"; + inputs = { + flake-parts.follows = "flake-parts"; + import-tree.follows = "import-tree"; + nixpkgs.follows = "nixpkgs"; + treefmt-nix.follows = "treefmt-nix"; + }; + }; nixcord = { url = "github:kaylorben/nixcord"; inputs.flake-parts.follows = "flake-parts"; diff --git a/modules/capabilities.nix b/modules/capabilities.nix index 52bea6b..d0c2ba1 100644 --- a/modules/capabilities.nix +++ b/modules/capabilities.nix @@ -2,6 +2,8 @@ inherit (lib) mkEnableOption; in { flake.modules.nixos.capabilities = { + key = "infra-nixos-capabilities"; + options.capabilities = { # keep-sorted start bluetooth = mkEnableOption "bluetooth support"; diff --git a/modules/desktop/cliphist.nix b/modules/desktop/cliphist.nix index 51e52d7..355c28a 100644 --- a/modules/desktop/cliphist.nix +++ b/modules/desktop/cliphist.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.cliphist = _: { + flake.modules.homeManager.cliphist = { services.cliphist.enable = true; }; } diff --git a/modules/desktop/hyprland/default.nix b/modules/desktop/hyprland/default.nix index cecdca9..06b4d4f 100644 --- a/modules/desktop/hyprland/default.nix +++ b/modules/desktop/hyprland/default.nix @@ -25,8 +25,6 @@ pkgs-unstable = inputs.hyprland.inputs.nixpkgs.legacyPackages.${system}; in { - imports = [self.modules.nixos.uwsm]; - nixpkgs.overlays = [self.overlays.hyprland]; programs.hyprland = { @@ -43,41 +41,14 @@ }; }; - flake.modules.homeManager.hyprland = { - # keep-sorted start - config, - inputs, - lib, - # keep-sorted end - ... - }: let - inherit - (lib) - # keep-sorted start - concatStringsSep - mkOption - types - # keep-sorted end - ; - - cfg = config.programs.nixhypr; - in { - imports = [ + flake.modules.homeManager.hyprland = {self, ...}: { + imports = with self.modules.homeManager; [ # keep-sorted start - inputs.nixhypr.homeManagerModules.default - self.modules.homeManager.uwsm + nixhypr + uwsm # keep-sorted end ]; - options.programs.nixhypr = { - extraLuaSnippets = mkOption { - description = "Lua snippets concatenated into nixhypr's extraLua."; - - type = types.listOf types.lines; - default = []; - }; - }; - config = { wayland.windowManager.hyprland = { enable = true; @@ -87,10 +58,7 @@ portalPackage = null; }; - programs.nixhypr = { - enable = true; - extraLua = concatStringsSep "\n" cfg.extraLuaSnippets; - }; + programs.nixhypr.enable = true; }; }; } diff --git a/modules/desktop/hyprland/gestures.nix b/modules/desktop/hyprland/gestures.nix index 6c8cd1f..2f5d08d 100644 --- a/modules/desktop/hyprland/gestures.nix +++ b/modules/desktop/hyprland/gestures.nix @@ -3,7 +3,6 @@ # keep-sorted start config, lib, - self, # keep-sorted end ... }: let @@ -24,13 +23,6 @@ cfg = config.programs.nixhypr.touch.enable; in { - imports = [ - # keep-sorted start - noctalia - overzicht - # keep-sorted end - ]; - options.programs.nixhypr.touch.enable = mkEnableOption "Enable touch-specific configuration"; config = mkIf cfg { diff --git a/modules/desktop/hyprland/keybinds/applications.nix b/modules/desktop/hyprland/keybinds/applications.nix index 704f598..6ca0c29 100644 --- a/modules/desktop/hyprland/keybinds/applications.nix +++ b/modules/desktop/hyprland/keybinds/applications.nix @@ -1,4 +1,4 @@ -_: { +{ flake.modules.homeManager.hyprland = { # keep-sorted start config, @@ -8,64 +8,66 @@ _: { # keep-sorted end ... }: let - inherit (lib) getExe; inherit (lib.self) mkNixhyprBindGroup; - - # keep-sorted start - ghostty = "${getExe config.programs.ghostty.package} --initial-window=false +new-window"; - runapp = getExe pkgs.runapp; - # keep-sorted end - - app = command: "${runapp} ${command}"; in { imports = with self.modules.homeManager; [ # keep-sorted start discord ghostty - noctalia zen # keep-sorted end ]; - config.programs.nixhypr.bindGroups = [ - (mkNixhyprBindGroup "Applications" [ - # keep-sorted start block=yes newline_separated=yes - { - description = "Browser"; + config = let + inherit (lib) getExe; - keys = ["SUPER" "B"]; - exec = app (getExe config.programs.zen-browser.package); - } + # keep-sorted start + ghostty = "${getExe config.programs.ghostty.package} --initial-window=false +new-window"; + runapp = getExe pkgs.runapp; + # keep-sorted end - { - description = "Discord"; + app = command: "${runapp} ${command}"; + in { + programs.nixhypr.bindGroups = [ + (mkNixhyprBindGroup "Applications" [ + # keep-sorted start block=yes newline_separated=yes + { + description = "Browser"; - keys = ["SUPER" "N"]; - exec = app (getExe config.programs.nixcord.equibop.package); - } + keys = ["SUPER" "B"]; + exec = app (getExe config.programs.zen-browser.package); + } - { - description = "File manager"; + { + description = "Discord"; - keys = ["SUPER" "E"]; - exec = app "${ghostty} -- ${getExe pkgs.yazi}"; - } + keys = ["SUPER" "N"]; + exec = app (getExe config.programs.nixcord.equibop.package); + } - { - description = "Steam"; + { + description = "File manager"; - keys = ["SUPER" "M"]; - exec = app "steam"; - } + keys = ["SUPER" "E"]; + exec = app "${ghostty} -- ${getExe pkgs.yazi}"; + } - { - description = "Terminal"; + { + description = "Steam"; - keys = ["SUPER" "Return"]; - exec = app ghostty; - } - # keep-sorted end - ]) - ]; + keys = ["SUPER" "M"]; + exec = app "steam"; + } + + { + description = "Terminal"; + + keys = ["SUPER" "Return"]; + exec = app ghostty; + } + # keep-sorted end + ]) + ]; + }; }; } diff --git a/modules/desktop/hyprland/keybinds/brightness.nix b/modules/desktop/hyprland/keybinds/brightness.nix index cee6c91..d53baf1 100644 --- a/modules/desktop/hyprland/keybinds/brightness.nix +++ b/modules/desktop/hyprland/keybinds/brightness.nix @@ -1,9 +1,8 @@ -_: { +{ flake.modules.homeManager.hyprland = { # keep-sorted start config, lib, - self, # keep-sorted end ... }: let @@ -21,8 +20,6 @@ _: { noctalia = "${getExe' config.programs.noctalia-shell.package "noctalia-shell"} ipc call"; in { - imports = [self.modules.homeManager.noctalia]; - options.hyprland.brightness.enable = mkEnableOption "function-row brightness keybindings"; config.programs.nixhypr.bindGroups = [ diff --git a/modules/desktop/hyprland/keybinds/default.nix b/modules/desktop/hyprland/keybinds/default.nix index b8194bf..244750e 100644 --- a/modules/desktop/hyprland/keybinds/default.nix +++ b/modules/desktop/hyprland/keybinds/default.nix @@ -1,6 +1,12 @@ {self, ...}: { - flake.modules.homeManager.hyprland = _: { - imports = [self.modules.homeManager.nixhyprBinds]; + flake.modules.homeManager.hyprland = { + imports = with self.modules.homeManager; [ + # keep-sorted start + nixhyprBinds + noctalia + overzicht + # keep-sorted end + ]; config.programs.nixhypr.settings.binds.movefocus_cycles_fullscreen = true; }; diff --git a/modules/desktop/hyprland/keybinds/groups.nix b/modules/desktop/hyprland/keybinds/groups.nix index 6556d74..12bf92c 100644 --- a/modules/desktop/hyprland/keybinds/groups.nix +++ b/modules/desktop/hyprland/keybinds/groups.nix @@ -1,4 +1,4 @@ -_: { +{ flake.modules.homeManager.hyprland = {lib, ...}: let inherit (lib) concatLists; inherit diff --git a/modules/desktop/hyprland/keybinds/layout-and-resize.nix b/modules/desktop/hyprland/keybinds/layout-and-resize.nix index 60459a7..84a8a00 100644 --- a/modules/desktop/hyprland/keybinds/layout-and-resize.nix +++ b/modules/desktop/hyprland/keybinds/layout-and-resize.nix @@ -1,4 +1,4 @@ -_: { +{ flake.modules.homeManager.hyprland = {lib, ...}: let inherit (lib) concatLists; inherit diff --git a/modules/desktop/hyprland/keybinds/media.nix b/modules/desktop/hyprland/keybinds/media.nix index 546e217..bee6e41 100644 --- a/modules/desktop/hyprland/keybinds/media.nix +++ b/modules/desktop/hyprland/keybinds/media.nix @@ -1,9 +1,8 @@ -_: { +{ flake.modules.homeManager.hyprland = { # keep-sorted start config, lib, - self, # keep-sorted end ... }: let @@ -12,8 +11,6 @@ _: { noctalia = "${getExe' config.programs.noctalia-shell.package "noctalia-shell"} ipc call"; in { - imports = [self.modules.homeManager.noctalia]; - config.programs.nixhypr.bindGroups = [ (mkNixhyprBindGroup "Media" [ # keep-sorted start block=yes newline_separated=yes diff --git a/modules/desktop/hyprland/keybinds/screenshots-and-color.nix b/modules/desktop/hyprland/keybinds/screenshots-and-color.nix index cb5b377..4e6b480 100644 --- a/modules/desktop/hyprland/keybinds/screenshots-and-color.nix +++ b/modules/desktop/hyprland/keybinds/screenshots-and-color.nix @@ -1,4 +1,4 @@ -_: { +{ flake.modules.homeManager.hyprland = { # keep-sorted start config, diff --git a/modules/desktop/hyprland/keybinds/shell.nix b/modules/desktop/hyprland/keybinds/shell.nix index 888c880..a3d0c0f 100644 --- a/modules/desktop/hyprland/keybinds/shell.nix +++ b/modules/desktop/hyprland/keybinds/shell.nix @@ -1,9 +1,8 @@ -_: { +{ flake.modules.homeManager.hyprland = { # keep-sorted start config, lib, - self, # keep-sorted end ... }: let @@ -12,8 +11,6 @@ _: { noctalia = "${getExe' config.programs.noctalia-shell.package "noctalia-shell"} ipc call"; in { - imports = [self.modules.homeManager.noctalia]; - config.programs.nixhypr.bindGroups = [ (mkNixhyprBindGroup "Shell" [ # keep-sorted start block=yes newline_separated=yes diff --git a/modules/desktop/hyprland/keybinds/system.nix b/modules/desktop/hyprland/keybinds/system.nix index f62e432..430ae92 100644 --- a/modules/desktop/hyprland/keybinds/system.nix +++ b/modules/desktop/hyprland/keybinds/system.nix @@ -1,9 +1,8 @@ -_: { +{ flake.modules.homeManager.hyprland = { # keep-sorted start config, lib, - self, # keep-sorted end ... }: let @@ -21,13 +20,6 @@ _: { overzicht = "${getExe config.programs.overzicht.package} ipc call"; # keep-sorted end in { - imports = [ - # keep-sorted start - noctalia - overzicht - # keep-sorted end - ]; - config.programs.nixhypr.bindGroups = [ (mkNixhyprBindGroup "System" [ # keep-sorted start block=yes newline_separated=yes diff --git a/modules/desktop/hyprland/keybinds/window-focus.nix b/modules/desktop/hyprland/keybinds/window-focus.nix index 3cd8ee7..ef5f5e4 100644 --- a/modules/desktop/hyprland/keybinds/window-focus.nix +++ b/modules/desktop/hyprland/keybinds/window-focus.nix @@ -1,4 +1,4 @@ -_: { +{ flake.modules.homeManager.hyprland = {lib, ...}: let inherit (lib.self) diff --git a/modules/desktop/hyprland/keybinds/window-management.nix b/modules/desktop/hyprland/keybinds/window-management.nix index 990a31d..804f9b1 100644 --- a/modules/desktop/hyprland/keybinds/window-management.nix +++ b/modules/desktop/hyprland/keybinds/window-management.nix @@ -1,4 +1,4 @@ -_: { +{ flake.modules.homeManager.hyprland = {lib, ...}: let inherit (lib.self) mkNixhyprBindGroup; in { diff --git a/modules/desktop/hyprland/keybinds/window-move.nix b/modules/desktop/hyprland/keybinds/window-move.nix index f3e26f7..b27480e 100644 --- a/modules/desktop/hyprland/keybinds/window-move.nix +++ b/modules/desktop/hyprland/keybinds/window-move.nix @@ -1,4 +1,4 @@ -_: { +{ flake.modules.homeManager.hyprland = {lib, ...}: let inherit (lib.self) diff --git a/modules/desktop/hyprland/keybinds/workspaces.nix b/modules/desktop/hyprland/keybinds/workspaces.nix index 3ab9396..7f5f12e 100644 --- a/modules/desktop/hyprland/keybinds/workspaces.nix +++ b/modules/desktop/hyprland/keybinds/workspaces.nix @@ -1,4 +1,4 @@ -_: { +{ flake.modules.homeManager.hyprland = {lib, ...}: let inherit (lib.self) diff --git a/modules/desktop/hyprland/picker.nix b/modules/desktop/hyprland/picker.nix index 952fa75..95c3af0 100644 --- a/modules/desktop/hyprland/picker.nix +++ b/modules/desktop/hyprland/picker.nix @@ -1,5 +1,5 @@ -{pkgs, ...}: { - flake.modules.homeManager.hyprland = { +{ + flake.modules.homeManager.hyprland = {pkgs, ...}: { home.packages = [pkgs.hyprpicker]; }; } diff --git a/modules/desktop/mangohud.nix b/modules/desktop/mangohud.nix index 858f6d3..7681d2e 100644 --- a/modules/desktop/mangohud.nix +++ b/modules/desktop/mangohud.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.mangohud = _: { + flake.modules.homeManager.mangohud = { programs.mangohud = { enable = true; diff --git a/modules/desktop/noctalia/audio.nix b/modules/desktop/noctalia/audio.nix index 167590e..eecf742 100644 --- a/modules/desktop/noctalia/audio.nix +++ b/modules/desktop/noctalia/audio.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.noctalia = _: { + flake.modules.homeManager.noctalia = { programs.noctalia-shell.settings.audio = { # keep-sorted start cavaFrameRate = 60; diff --git a/modules/desktop/noctalia/brightness.nix b/modules/desktop/noctalia/brightness.nix index 814dfd7..21914ab 100644 --- a/modules/desktop/noctalia/brightness.nix +++ b/modules/desktop/noctalia/brightness.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.noctalia = _: { + flake.modules.homeManager.noctalia = { programs.noctalia-shell.settings.brightness = { # keep-sorted start enableDdcSupport = true; diff --git a/modules/desktop/noctalia/calendar.nix b/modules/desktop/noctalia/calendar.nix index 7a8c689..5db8184 100644 --- a/modules/desktop/noctalia/calendar.nix +++ b/modules/desktop/noctalia/calendar.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.noctalia = _: { + flake.modules.homeManager.noctalia = { programs.noctalia-shell = { # Enable calendar support in the flake-provided Noctalia build. packageOverrides.calendarSupport = true; diff --git a/modules/desktop/noctalia/default.nix b/modules/desktop/noctalia/default.nix index 5c07ab8..077e02f 100644 --- a/modules/desktop/noctalia/default.nix +++ b/modules/desktop/noctalia/default.nix @@ -1,4 +1,10 @@ -{inputs, ...}: { +{ + # keep-sorted start + inputs, + self, + # keep-sorted end + ... +}: { flake-file.inputs = { noctalia = { url = "github:noctalia-dev/noctalia-shell?ref=v4.7.7"; @@ -17,6 +23,8 @@ }; flake.modules.nixos.noctalia = { + nixpkgs.overlays = [self.overlays.pkgs]; + nix.settings = let cache = "https://noctalia.cachix.org"; in { diff --git a/modules/desktop/noctalia/dock.nix b/modules/desktop/noctalia/dock.nix index 9dda616..c5302db 100644 --- a/modules/desktop/noctalia/dock.nix +++ b/modules/desktop/noctalia/dock.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.noctalia = _: { + flake.modules.homeManager.noctalia = { programs.noctalia-shell.settings.dock = { # keep-sorted start backgroundOpacity = 0.95; diff --git a/modules/desktop/noctalia/general.nix b/modules/desktop/noctalia/general.nix index 4554775..da16bd4 100644 --- a/modules/desktop/noctalia/general.nix +++ b/modules/desktop/noctalia/general.nix @@ -1,12 +1,10 @@ -{self, ...}: { +{ flake.modules.homeManager.noctalia = {config, ...}: { - imports = [self.modules.homeManager.hyprland]; - programs.noctalia-shell.settings.general = let # Use sharp corners (no rounding) for consistent design. radius = 0; - cfgTouch = config.programs.nixhypr.touch.enable; + cfgTouch = config.programs.nixhypr.touch.enable or false; in { # keep-sorted start animationSpeed = 2; diff --git a/modules/desktop/noctalia/notifications.nix b/modules/desktop/noctalia/notifications.nix index 7994a78..b994dfd 100644 --- a/modules/desktop/noctalia/notifications.nix +++ b/modules/desktop/noctalia/notifications.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.noctalia = _: { + flake.modules.homeManager.noctalia = { programs.noctalia-shell.settings.notifications = { # keep-sorted start criticalUrgencyDuration = 8; diff --git a/modules/desktop/noctalia/sessionmenu.nix b/modules/desktop/noctalia/sessionmenu.nix index 0a9cd57..ddff77c 100644 --- a/modules/desktop/noctalia/sessionmenu.nix +++ b/modules/desktop/noctalia/sessionmenu.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.noctalia = _: { + flake.modules.homeManager.noctalia = { programs.noctalia-shell.settings.sessionMenu = { # keep-sorted start countdownDuration = 8000; diff --git a/modules/desktop/noctalia/ui.nix b/modules/desktop/noctalia/ui.nix index 14ffabe..91d0def 100644 --- a/modules/desktop/noctalia/ui.nix +++ b/modules/desktop/noctalia/ui.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.noctalia = _: { + flake.modules.homeManager.noctalia = { programs.noctalia-shell.settings.ui = { # keep-sorted start boxBorderEnabled = true; diff --git a/modules/desktop/uwsm.nix b/modules/desktop/uwsm.nix index 0d7dddb..02e4098 100644 --- a/modules/desktop/uwsm.nix +++ b/modules/desktop/uwsm.nix @@ -1,4 +1,4 @@ -_: { +{ flake.modules.nixos.uwsm = {pkgs, ...}: { programs.uwsm.package = pkgs.uwsm.override {uuctlSupport = false;}; }; diff --git a/modules/desktop/xdg/applications/code.nix b/modules/desktop/xdg/applications/code.nix index 65d7e38..2417e60 100644 --- a/modules/desktop/xdg/applications/code.nix +++ b/modules/desktop/xdg/applications/code.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.xdgApplications = _: { + flake.modules.homeManager.xdgApplications = { xdg.mimeApps.defaultApplications = { # keep-sorted start "application/sql" = "nvim.desktop"; diff --git a/modules/desktop/xdg/applications/default.nix b/modules/desktop/xdg/applications/default.nix index 95e310b..ab22600 100644 --- a/modules/desktop/xdg/applications/default.nix +++ b/modules/desktop/xdg/applications/default.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.xdgApplications = _: { + flake.modules.homeManager.xdgApplications = { xdg.mimeApps.enable = true; }; } diff --git a/modules/desktop/xdg/applications/files.nix b/modules/desktop/xdg/applications/files.nix index c68312a..570a3aa 100644 --- a/modules/desktop/xdg/applications/files.nix +++ b/modules/desktop/xdg/applications/files.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.xdgApplications = _: { + flake.modules.homeManager.xdgApplications = { xdg.mimeApps.defaultApplications = { # keep-sorted start "application/x-modrinth-modpack+zip" = "org.prismlauncher.PrismLauncher.desktop"; diff --git a/modules/desktop/xdg/default.nix b/modules/desktop/xdg/default.nix index 2a108fb..97732c3 100644 --- a/modules/desktop/xdg/default.nix +++ b/modules/desktop/xdg/default.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.xdg = _: { + flake.modules.homeManager.xdg = { xdg.enable = true; }; } diff --git a/modules/desktop/xdg/dirs.nix b/modules/desktop/xdg/dirs.nix index 020ab24..1ab489b 100644 --- a/modules/desktop/xdg/dirs.nix +++ b/modules/desktop/xdg/dirs.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.xdgDirs = _: { + flake.modules.homeManager.xdgDirs = { home.preferXdgDirectories = true; xdg.userDirs = { diff --git a/modules/desktop/xdg/polkit.nix b/modules/desktop/xdg/polkit.nix index 550a2cd..79d3c12 100644 --- a/modules/desktop/xdg/polkit.nix +++ b/modules/desktop/xdg/polkit.nix @@ -1,9 +1,9 @@ { - flake.modules.homeManager.polkit = _: { + flake.modules.homeManager.polkit = { services.polkit-gnome.enable = true; }; - flake.modules.nixos.polkit = _: { + flake.modules.nixos.polkit = { security.polkit.enable = true; }; } diff --git a/modules/development/devshell.nix b/modules/development/devshell.nix index be37708..3880a21 100644 --- a/modules/development/devshell.nix +++ b/modules/development/devshell.nix @@ -1,4 +1,4 @@ -_: { +{ perSystem = {pkgs, ...}: let inherit (pkgs) mkShell; in { diff --git a/modules/hosts/default.nix b/modules/hosts/default.nix new file mode 100644 index 0000000..cb416c2 --- /dev/null +++ b/modules/hosts/default.nix @@ -0,0 +1,28 @@ +{ + inputs, + lib, + self, + ... +}: let + hosts = { + # keep-sorted start + desktop = "x86_64-linux"; + laptop = "x86_64-linux"; + vm = "x86_64-linux"; + # keep-sorted end + }; +in { + flake.nixosConfigurations = lib.mapAttrs (name: system: + self.lib.nixosSystem { + specialArgs = { + inherit inputs self; + inherit (self) vars; + }; + + modules = [ + self.modules.nixos.${name} + {nixpkgs.hostPlatform = lib.mkDefault system;} + ]; + }) + hosts; +} diff --git a/modules/hosts/desktop/default.nix b/modules/hosts/desktop/default.nix new file mode 100644 index 0000000..ed5e987 --- /dev/null +++ b/modules/hosts/desktop/default.nix @@ -0,0 +1,25 @@ +{self, ...}: { + flake.modules.nixos.desktop = { + imports = with self.modules.nixos; [ + # keep-sorted start + personal + roccat + # keep-sorted end + ]; + + # System version for state compatibility - do not modify. + system.stateVersion = "26.05"; + + networking.hostName = "desktop"; + + # Primary nvme disk for disko partitioning. + disko.selectedDisk = "/dev/nvme0n1"; + + # Enable amd rocm support for gpu. + nixpkgs.config.rocmSupport = true; + + hardware.wooting.enable = true; + + services.timezone = "Europe/Amsterdam"; + }; +} diff --git a/modules/hosts/desktop/hardware.nix b/modules/hosts/desktop/hardware.nix new file mode 100644 index 0000000..1d7f028 --- /dev/null +++ b/modules/hosts/desktop/hardware.nix @@ -0,0 +1,32 @@ +{ + flake.modules.nixos.desktop = { + # keep-sorted start + config, + modulesPath, + # keep-sorted end + ... + }: { + imports = [(modulesPath + "/installer/scan/not-detected.nix")]; + + # keep-sorted start block=yes newline_separated=yes + # Kernel modules for desktop hardware support. + boot.initrd.availableKernelModules = [ + # keep-sorted start + "ahci" + "nvme" + "sd_mod" + "uas" + "usb_storage" + "usbhid" + "xhci_pci" + # keep-sorted end + ]; + + # Enable intel virtualization support. + boot.kernelModules = ["kvm-intel"]; + + # Enable intel microcode updates when firmware is available. + hardware.cpu.intel.updateMicrocode = config.hardware.enableRedistributableFirmware; + # keep-sorted end + }; +} diff --git a/modules/hosts/desktop/home.nix b/modules/hosts/desktop/home.nix new file mode 100644 index 0000000..21bb4f6 --- /dev/null +++ b/modules/hosts/desktop/home.nix @@ -0,0 +1,61 @@ +{ + flake.modules.nixos.desktop = { + self, + vars, + ... + }: let + inherit (vars) username; + in { + home-manager.users.${username} = { + imports = with self.modules.homeManager; [ + # keep-sorted start + personal + # keep-sorted end + ]; + + # keep-sorted start block=yes newline_separated=yes + # Enable rocm gpu backend for system monitoring. + programs.btop.gpuBackends = ["rocm"]; + + # Configure dual monitor setup. + programs.nixhypr.monitors = [ + { + output = "DP-1"; + mode = "1920x1080@144"; + position = "-1920x96"; + scale = "1"; + extra.vrr = 0; + } + + { + output = "DP-2"; + mode = "2560x1440@170"; + position = "0x0"; + scale = "1"; + } + ]; + + programs.noctalia-shell = { + # keep-sorted start newline_separated=yes + # Keep the desktop weather location in sops. + location.source = "sops"; + + # Enable gpu acceleration for noctalia. + systemMonitor.enableGpu = true; + # keep-sorted end + }; + + # Gpu monitoring support for multi-gpu desktop. + programs.nvtop.types = [ + # keep-sorted start + "amd" + "intel" + # keep-sorted end + ]; + + # Browser memory allocation for desktop usage. + programs.zen-browser.profiles.default.preferences.commitSpace = 25698; + # keep-sorted end + }; + }; +} diff --git a/modules/hosts/laptop/default.nix b/modules/hosts/laptop/default.nix new file mode 100644 index 0000000..8f9b39a --- /dev/null +++ b/modules/hosts/laptop/default.nix @@ -0,0 +1,89 @@ +{self, ...}: { + flake.modules.nixos.laptop = { + imports = with self.modules.nixos; [ + # keep-sorted start + bluetooth + lidswitch + personal + roccat + scx + tlp + wifi + # keep-sorted end + ]; + + # System version for state compatibility - do not modify. + system.stateVersion = "25.05"; + + networking.hostName = "laptop"; + + # Primary nvme disk for disko partitioning. + disko.selectedDisk = "/dev/nvme0n1"; + + services.timezone = "automatic-timezoned"; + + # Enable rcu lazy mode for better battery life. + tweaks.rcuLazy.enable = true; + + powerManagement.powertop.enable = true; + + # Advanced power management for laptop battery optimization. + services = { + thermald.enable = true; + + tlp.settings = { + # Cpu performance profiles: maximize performance on ac, conserve battery on bat. + # keep-sorted start + CPU_ENERGY_PERF_POLICY_ON_BAT = "power"; + CPU_SCALING_GOVERNOR_ON_AC = "performance"; + CPU_SCALING_GOVERNOR_ON_BAT = "powersave"; + # keep-sorted end + + # Cpu frequency limits: allow full range on ac, cap at 30% on battery. + # keep-sorted start + CPU_MAX_PERF_ON_AC = 100; + CPU_MAX_PERF_ON_BAT = 30; + CPU_MIN_PERF_ON_AC = 0; + CPU_MIN_PERF_ON_BAT = 0; + # keep-sorted end + + # Disable cpu boost because it makes noise FOR SOME REASON ?!. + CPU_BOOST_ON_AC = 0; + + # Platform power profiles: balanced on ac, low power on battery. + # keep-sorted start + PLATFORM_PROFILE_ON_AC = "balanced"; + PLATFORM_PROFILE_ON_BAT = "low-power"; + # keep-sorted end + + # Sleep modes. + # keep-sorted start + MEM_SLEEP_ON_AC = "s2idle"; + MEM_SLEEP_ON_BAT = "s2idle"; + # keep-sorted end + + # Storage device for power management. + DISK_DEVICES = "nvme-Samsung_SSD_980_PRO_500GB_S5GYNX0W331360B"; + + # Intel gpu frequency limits: high performance on ac, reduced on battery. + # keep-sorted start + INTEL_GPU_BOOST_FREQ_ON_AC = 1300; + INTEL_GPU_BOOST_FREQ_ON_BAT = 700; + INTEL_GPU_MAX_FREQ_ON_AC = 1300; + INTEL_GPU_MAX_FREQ_ON_BAT = 450; + INTEL_GPU_MIN_FREQ_ON_AC = 100; + INTEL_GPU_MIN_FREQ_ON_BAT = 100; + # keep-sorted end + + # Disable unused amd gpu features since this is intel graphics. + # keep-sorted start + AMDGPU_ABM_LEVEL_ON_AC = ""; + AMDGPU_ABM_LEVEL_ON_BAT = ""; + PCIE_ASPM_ON_AC = ""; + RADEON_DPM_PERF_LEVEL_ON_AC = ""; + RADEON_DPM_PERF_LEVEL_ON_BAT = ""; + # keep-sorted end + }; + }; + }; +} diff --git a/modules/hosts/laptop/hardware.nix b/modules/hosts/laptop/hardware.nix new file mode 100644 index 0000000..30f626e --- /dev/null +++ b/modules/hosts/laptop/hardware.nix @@ -0,0 +1,33 @@ +{ + flake.modules.nixos.laptop = { + # keep-sorted start + config, + modulesPath, + # keep-sorted end + ... + }: { + imports = [ + (modulesPath + "/installer/scan/not-detected.nix") + ]; + + # keep-sorted start block=yes newline_separated=yes + # Kernel modules for laptop hardware support. + boot.initrd.availableKernelModules = [ + # keep-sorted start + "nvme" + "rtsx_pci_sdmmc" + "sd_mod" + "thunderbolt" + "usb_storage" + "xhci_pci" + # keep-sorted end + ]; + + # Enable intel virtualization support. + boot.kernelModules = ["kvm-intel"]; + + # Enable intel microcode updates when firmware is available. + hardware.cpu.intel.updateMicrocode = config.hardware.enableRedistributableFirmware; + # keep-sorted end + }; +} diff --git a/modules/hosts/laptop/home.nix b/modules/hosts/laptop/home.nix new file mode 100644 index 0000000..dfbaa35 --- /dev/null +++ b/modules/hosts/laptop/home.nix @@ -0,0 +1,62 @@ +{ + flake.modules.nixos.laptop = { + # keep-sorted start + self, + vars, + # keep-sorted end + ... + }: let + inherit (vars) username; + in { + home-manager.users.${username} = { + imports = with self.modules.homeManager; [ + # keep-sorted start + personal + # keep-sorted end + ]; + + # keep-sorted start block=yes newline_separated=yes + # Enable laptop hardware features. + programs.nixcord.equibop.camera.enable = true; + + # Enable laptop-specific hyprland features. + programs.nixhypr = { + # keep-sorted start block=yes newline_separated=yes + monitors = [ + { + output = "eDP-1"; + mode = "1920x1080@60"; + position = "0x0"; + scale = "1"; + } + ]; + + touch.enable = true; + # keep-sorted end + }; + + # Enable laptop-specific noctalia features. + programs.noctalia-shell = { + battery.enable = true; + idle = { + # keep-sorted start + brightness.enable = true; + suspend.enable = true; + # keep-sorted end + }; + }; + + # Gpu monitoring for intel integrated graphics. + programs.nvtop.types = ["intel"]; + + # Travel mode configuration for mobile usage. + programs.zen-browser.profiles.default.preferences = { + # keep-sorted start + commitSpace = 13107; + travel.enable = true; + # keep-sorted end + }; + # keep-sorted end + }; + }; +} diff --git a/modules/hosts/vm/default.nix b/modules/hosts/vm/default.nix new file mode 100644 index 0000000..9cc4db0 --- /dev/null +++ b/modules/hosts/vm/default.nix @@ -0,0 +1,26 @@ +{self, ...}: { + flake.modules.nixos.vm = { + imports = with self.modules.nixos; [ + # keep-sorted start + personal + # keep-sorted end + ]; + + networking.hostName = "vm"; + + # System version for state compatibility - do not modify. + system.stateVersion = "25.05"; + + # Virtual disk device for disko partitioning. + disko.selectedDisk = "/dev/vda"; + + services = { + timezone = "automatic-timezoned"; + + # keep-sorted start + qemuGuest.enable = true; + spice-vdagentd.enable = true; + # keep-sorted end + }; + }; +} diff --git a/modules/hosts/vm/hardware.nix b/modules/hosts/vm/hardware.nix new file mode 100644 index 0000000..942d14a --- /dev/null +++ b/modules/hosts/vm/hardware.nix @@ -0,0 +1,20 @@ +{ + flake.modules.nixos.vm = {modulesPath, ...}: { + imports = [(modulesPath + "/profiles/qemu-guest.nix")]; + + # keep-sorted start block=yes newline_separated=yes + # Kernel modules appropriate for generic vms. + boot.initrd.availableKernelModules = [ + # keep-sorted start + "ahci" + "sr_mod" + "virtio_blk" + "virtio_pci" + "xhci_pci" + # keep-sorted end + ]; + + boot.kernelModules = ["kvm-intel"]; + # keep-sorted end + }; +} diff --git a/modules/hosts/vm/home.nix b/modules/hosts/vm/home.nix new file mode 100644 index 0000000..d8f8643 --- /dev/null +++ b/modules/hosts/vm/home.nix @@ -0,0 +1,35 @@ +{ + flake.modules.nixos.vm = { + # keep-sorted start + self, + vars, + # keep-sorted end + ... + }: let + inherit (vars) username; + in { + home-manager.users.${username} = { + imports = with self.modules.homeManager; [ + # keep-sorted start + personal + # keep-sorted end + ]; + + # keep-sorted start block=yes newline_separated=yes + # Configure the vm display settings. + programs.nixhypr.monitors = [ + { + output = "Virtual-1"; + mode = "1920x1080@60"; + position = "0x0"; + scale = "1"; + extra.vrr = 0; + } + ]; + + # Browser memory allocation for vm environment. + programs.zen-browser.profiles.default.preferences.commitSpace = 6683; + # keep-sorted end + }; + }; +} diff --git a/modules/nix/home-manager.nix b/modules/nix/home-manager.nix index c7771ea..aebd33c 100644 --- a/modules/nix/home-manager.nix +++ b/modules/nix/home-manager.nix @@ -34,6 +34,7 @@ home-manager = { useGlobalPkgs = true; useUserPackages = true; + extraSpecialArgs = {inherit inputs self vars;}; startAsUserService = true; backupCommand = "${pkgs.trash-cli}/bin/trash"; diff --git a/modules/nixhypr-binds.nix b/modules/nixhypr/binds.nix similarity index 100% rename from modules/nixhypr-binds.nix rename to modules/nixhypr/binds.nix diff --git a/modules/nixhypr/default.nix b/modules/nixhypr/default.nix new file mode 100644 index 0000000..bdec653 --- /dev/null +++ b/modules/nixhypr/default.nix @@ -0,0 +1,44 @@ +{inputs, ...}: { + flake.modules.homeManager.nixhypr = { + # keep-sorted start + config, + lib, + # keep-sorted end + ... + }: let + inherit + (lib) + # keep-sorted start + concatStringsSep + mkEnableOption + mkIf + mkOption + types + # keep-sorted end + ; + + cfg = config.programs.nixhypr; + in { + imports = ["${inputs.nixhypr}/modules"]; + + options.programs.nixhypr = { + enable = mkEnableOption "nixhypr hyprland lua config generator"; + + extraLuaSnippets = mkOption { + description = "Lua snippets concatenated into nixhypr's extraLua."; + + type = types.listOf types.lines; + default = []; + }; + }; + + config = mkIf cfg.enable { + wayland.windowManager.hyprland = { + configType = "lua"; + extraConfig = cfg._generatedConfig; + }; + + programs.nixhypr.extraLua = concatStringsSep "\n" cfg.extraLuaSnippets; + }; + }; +} diff --git a/modules/pkgs/lutris.nix b/modules/pkgs/lutris.nix index 199d601..5c3f382 100644 --- a/modules/pkgs/lutris.nix +++ b/modules/pkgs/lutris.nix @@ -1,11 +1,5 @@ { perSystem = {pkgs, ...}: let - inherit - (builtins) - # keep-sorted start - filter - # keep-sorted end - ; inherit (pkgs) buildFHSEnv; # Slim lutris provides minimal lutris with essential dependencies. @@ -182,11 +176,8 @@ ]) ++ xorgDeps pkgs ++ gstreamerDeps pkgs; - - # Keep Lutris building while upstream openldap checks fail here. - customLdap = pkgs.openldap.overrideAttrs (_: {doCheck = false;}); in - filter (p: (p.pname or "") != "openldap") originalPkgs ++ [customLdap]; + originalPkgs; extraInstallCommands = '' mkdir -p $out/share diff --git a/modules/pkgs/preview/man.nix b/modules/pkgs/preview/man.nix index c23ae99..6b69628 100644 --- a/modules/pkgs/preview/man.nix +++ b/modules/pkgs/preview/man.nix @@ -1,4 +1,4 @@ -_: { +{ perSystem = {pkgs, ...}: { packages.man-preview = pkgs.writeShellApplication { name = "man-preview"; diff --git a/modules/pkgs/preview/text.nix b/modules/pkgs/preview/text.nix index 4a74834..5dc3208 100644 --- a/modules/pkgs/preview/text.nix +++ b/modules/pkgs/preview/text.nix @@ -1,4 +1,4 @@ -_: { +{ perSystem = {pkgs, ...}: { packages.text-preview = pkgs.writeShellApplication { # SPDX-License-Identifier: AGPL-3.0-or-later diff --git a/modules/profiles/base.nix b/modules/profiles/base.nix new file mode 100644 index 0000000..3c7dcd0 --- /dev/null +++ b/modules/profiles/base.nix @@ -0,0 +1,31 @@ +{self, ...}: { + flake.modules.nixos.base = { + imports = with self.modules.nixos; [ + # keep-sorted start + capabilities + disko + firmware + home-manager + kernel + lanzaboote + locale + network + nftables + nix + nix-ld + slim + stylixBase + timezone + tmp + tweaks + udisks2 + users + zram + # keep-sorted end + ]; + }; + + flake.modules.homeManager.base = { + imports = [self.modules.homeManager.stylixBase]; + }; +} diff --git a/modules/profiles/partitioning/default.nix b/modules/profiles/partitioning/default.nix index 8406572..67f2739 100644 --- a/modules/profiles/partitioning/default.nix +++ b/modules/profiles/partitioning/default.nix @@ -10,7 +10,7 @@ in { imports = [inputs.disko.nixosModules.disko]; - options.disko.disk = mkOption { + options.disko.selectedDisk = mkOption { type = types.str; example = "/dev/nvme0n1"; description = "Disk device to use for the selected disko layout."; diff --git a/modules/profiles/personal.nix b/modules/profiles/personal.nix index 0c4e10a..8e0e70f 100644 --- a/modules/profiles/personal.nix +++ b/modules/profiles/personal.nix @@ -1,37 +1,39 @@ {self, ...}: { flake.modules.nixos.personal = {config, ...}: { - imports = - (with self.modules.nixos; [ - # keep-sorted start - capabilities - disko - tmp - # keep-sorted end + imports = with self.modules; + [generic.determinate] + ++ (with nixos; [ + base - # Profile common. # keep-sorted start - home-manager - locale - slim + appimage + hyprland + java + noctalia + pipewire + polkit + power-profiles-daemon stylixPersonal - timezone - tweaks - users + tuigreet + upower + xdgPortal # keep-sorted end - ]) - ++ [self.modules.generic.determinate]; + ]); - disko.devices = (self.diskoConfigurations.ext4 config.disko.disk).disko.devices; + disko.devices = (self.diskoConfigurations.ext4 config.disko.selectedDisk).disko.devices; }; flake.modules.homeManager.personal = { imports = with self.modules.homeManager; [ - # Profile common. + base + # keep-sorted start env face git gtk + hyprland + nvtop # keep-sorted end ]; }; diff --git a/modules/profiles/stylix/base.nix b/modules/profiles/stylix/base.nix index 83620ea..967fd21 100644 --- a/modules/profiles/stylix/base.nix +++ b/modules/profiles/stylix/base.nix @@ -46,13 +46,21 @@ in { }; flake.modules.nixos.stylixBase = { + key = "infra-nixos-stylixBase"; + imports = [inputs.stylix.nixosModules.stylix]; stylix = stylixConfig; }; flake.modules.homeManager.stylixBase = { - imports = [inputs.stylix.homeModules.stylix]; + lib, + osConfig ? null, + ... + }: { + key = "infra-homeManager-stylixBase"; + + imports = lib.optional (osConfig == null) inputs.stylix.homeModules.stylix; stylix = stylixConfig; }; diff --git a/modules/profiles/stylix/personal.nix b/modules/profiles/stylix/personal.nix index b0a3259..4329115 100644 --- a/modules/profiles/stylix/personal.nix +++ b/modules/profiles/stylix/personal.nix @@ -1,11 +1,5 @@ -{ - # keep-sorted start - lib, - self, - # keep-sorted end - ... -}: let - inherit (lib.self) stylixDisabledTargets; +{self, ...}: let + inherit (self.lib.self) stylixDisabledTargets; disabledHomeTargets = stylixDisabledTargets [ # keep-sorted start @@ -20,6 +14,8 @@ ]; in { flake.modules.nixos.stylixPersonal = {pkgs, ...}: { + key = "infra-nixos-stylixPersonal"; + imports = with self.modules.nixos; [ # keep-sorted start nur @@ -70,6 +66,8 @@ in { }; flake.modules.homeManager.stylixPersonal = { + key = "infra-homeManager-stylixPersonal"; + imports = [self.modules.homeManager.stylixBase]; stylix = { diff --git a/modules/programs/cli/direnv.nix b/modules/programs/cli/direnv.nix index 5785e9a..fa8a74b 100644 --- a/modules/programs/cli/direnv.nix +++ b/modules/programs/cli/direnv.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.direnv = _: { + flake.modules.homeManager.direnv = { programs.direnv = { enable = true; diff --git a/modules/programs/cli/fd.nix b/modules/programs/cli/fd.nix index 0cf7a77..67e1611 100644 --- a/modules/programs/cli/fd.nix +++ b/modules/programs/cli/fd.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.fd = _: { + flake.modules.homeManager.fd = { programs.fd = { enable = true; diff --git a/modules/programs/cli/nys.nix b/modules/programs/cli/nys.nix index c73c2fd..97a5073 100644 --- a/modules/programs/cli/nys.nix +++ b/modules/programs/cli/nys.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.nys = _: { + flake.modules.homeManager.nys = { programs.nix-your-shell = { enable = true; diff --git a/modules/programs/cli/ouch.nix b/modules/programs/cli/ouch.nix index 3c20c4b..37abf99 100644 --- a/modules/programs/cli/ouch.nix +++ b/modules/programs/cli/ouch.nix @@ -1,4 +1,4 @@ -_: { +{ flake.modules.homeManager.ouch = { # keep-sorted start lib, diff --git a/modules/programs/cli/ripgrep-all/default.nix b/modules/programs/cli/ripgrep-all/default.nix index e54bc49..20f8580 100644 --- a/modules/programs/cli/ripgrep-all/default.nix +++ b/modules/programs/cli/ripgrep-all/default.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.ripgrep-all = _: { + flake.modules.homeManager.ripgrep-all = { programs.ripgrep-all.enable = true; }; } diff --git a/modules/programs/cli/starship/default.nix b/modules/programs/cli/starship/default.nix index 53f1054..673c886 100644 --- a/modules/programs/cli/starship/default.nix +++ b/modules/programs/cli/starship/default.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.starship = _: { + flake.modules.homeManager.starship = { programs.starship.enable = true; }; } diff --git a/modules/programs/cli/starship/git.nix b/modules/programs/cli/starship/git.nix index e245bc4..e269212 100644 --- a/modules/programs/cli/starship/git.nix +++ b/modules/programs/cli/starship/git.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.starship = _: { + flake.modules.homeManager.starship = { programs.starship.settings = { # keep-sorted start block=yes newline_separated=yes fossil_branch = { diff --git a/modules/programs/git.nix b/modules/programs/git.nix index 79ab7fe..d3b3d29 100644 --- a/modules/programs/git.nix +++ b/modules/programs/git.nix @@ -1,6 +1,5 @@ { # keep-sorted start - lib, self, # keep-sorted end ... @@ -8,6 +7,7 @@ flake.modules.homeManager.git = { # keep-sorted start config, + lib, osConfig, pkgs, vars, diff --git a/modules/programs/gui/discord/plugins/core.nix b/modules/programs/gui/discord/plugins/core.nix index 1a47744..ce378a4 100644 --- a/modules/programs/gui/discord/plugins/core.nix +++ b/modules/programs/gui/discord/plugins/core.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.discord = _: { + flake.modules.homeManager.discord = { programs.nixcord.config.plugins = { # keep-sorted start block=yes newline_separated=yes alwaysTrust.enable = true; diff --git a/modules/programs/gui/discord/plugins/integrations.nix b/modules/programs/gui/discord/plugins/integrations.nix index b6d4e15..b4494d9 100644 --- a/modules/programs/gui/discord/plugins/integrations.nix +++ b/modules/programs/gui/discord/plugins/integrations.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.discord = _: { + flake.modules.homeManager.discord = { programs.nixcord.config.plugins = { # keep-sorted start block=yes newline_separated=yes dragify.enable = true; diff --git a/modules/programs/gui/discord/plugins/interface.nix b/modules/programs/gui/discord/plugins/interface.nix index cdb48f5..6cba93f 100644 --- a/modules/programs/gui/discord/plugins/interface.nix +++ b/modules/programs/gui/discord/plugins/interface.nix @@ -1,12 +1,11 @@ {self, ...}: { flake.modules.homeManager.discord = { # keep-sorted start - config, lib, # keep-sorted end ... }: let - inherit (lib) fromHexString mkEnableOption; + inherit (lib) mkEnableOption; in # Interface and layout related plugins. { @@ -105,25 +104,6 @@ previewMessage.enable = true; - questify = { - enable = true; - # keep-sorted start - completeGameQuestsInBackground = true; - completeVideoQuestsInBackground = true; - # keep-sorted end - fetchingQuestsInterval = 0; - # keep-sorted start - questButtonDisplay = "never"; - questButtonUnclaimed = "none"; - # keep-sorted end - # keep-sorted start - restyleQuestsClaimed = fromHexString config.lib.stylix.colors.base0E; - restyleQuestsExpired = fromHexString config.lib.stylix.colors.base00; - restyleQuestsIgnored = fromHexString config.lib.stylix.colors.base08; - restyleQuestsUnclaimed = fromHexString config.lib.stylix.colors.base0D; - # keep-sorted end - }; - readAllNotificationsButton.enable = true; roleColorEverywhere.enable = true; diff --git a/modules/programs/gui/discord/plugins/social.nix b/modules/programs/gui/discord/plugins/social.nix index 14bfff2..3e93ec8 100644 --- a/modules/programs/gui/discord/plugins/social.nix +++ b/modules/programs/gui/discord/plugins/social.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.discord = _: { + flake.modules.homeManager.discord = { programs.nixcord.config.plugins = { # keep-sorted start block=yes newline_separated=yes MutualGroupDMs.enable = true; diff --git a/modules/programs/gui/discord/settings.nix b/modules/programs/gui/discord/settings.nix index 1e1bcf8..d6e01ac 100644 --- a/modules/programs/gui/discord/settings.nix +++ b/modules/programs/gui/discord/settings.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.discord = _: { + flake.modules.homeManager.discord = { programs.nixcord = { # Write main equibop configuration. config = { diff --git a/modules/programs/gui/ghostty/keybinds.nix b/modules/programs/gui/ghostty/keybinds.nix index 1f80f41..1fe56bd 100644 --- a/modules/programs/gui/ghostty/keybinds.nix +++ b/modules/programs/gui/ghostty/keybinds.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.ghostty = _: { + flake.modules.homeManager.ghostty = { programs.ghostty.settings.keybind = [ # keep-sorted start "alt+f4=unbind" diff --git a/modules/programs/gui/ghostty/settings.nix b/modules/programs/gui/ghostty/settings.nix index 61d647b..5e07d1b 100644 --- a/modules/programs/gui/ghostty/settings.nix +++ b/modules/programs/gui/ghostty/settings.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.ghostty = _: { + flake.modules.homeManager.ghostty = { programs.ghostty.settings = { # Font settings. font-feature = "-calt, -liga, -dlig"; diff --git a/modules/programs/gui/sober.nix b/modules/programs/gui/sober.nix index 6ce21e6..03dd09c 100644 --- a/modules/programs/gui/sober.nix +++ b/modules/programs/gui/sober.nix @@ -1,5 +1,5 @@ {self, ...}: { - flake.modules.homeManager.sober = _: let + flake.modules.homeManager.sober = let pkg = "org.vinegarhq.Sober"; in { imports = [self.modules.homeManager.flatpak]; diff --git a/modules/programs/gui/zen/chrome.nix b/modules/programs/gui/zen/chrome.nix index ab49f80..2fed7f5 100644 --- a/modules/programs/gui/zen/chrome.nix +++ b/modules/programs/gui/zen/chrome.nix @@ -1,4 +1,18 @@ {self, ...}: { + flake-file.inputs = { + nix-userstyles = { + url = "github:adam01110/nix-userstyles"; + inputs = { + # keep-sorted start + flake-parts.follows = "flake-parts"; + import-tree.follows = "import-tree"; + nixpkgs.follows = "nixpkgs"; + treefmt-nix.follows = "treefmt-nix"; + # keep-sorted end + }; + }; + }; + flake.modules.homeManager.zen = { # keep-sorted start config, diff --git a/modules/programs/ssh.nix b/modules/programs/ssh.nix index bf54fdd..1161cf0 100644 --- a/modules/programs/ssh.nix +++ b/modules/programs/ssh.nix @@ -40,9 +40,9 @@ enableDefaultConfig = false; # Dedicate a key for github traffic to keep identities separate. - matchBlocks."github.com" = { - hostname = "github.com"; - identityFile = "~/.ssh/git"; + settings."github.com" = { + HostName = "github.com"; + IdentityFile = "~/.ssh/git"; }; # Pull in the sops-generated server host. diff --git a/modules/programs/tui/cava.nix b/modules/programs/tui/cava.nix index 5e43f59..165e5a2 100644 --- a/modules/programs/tui/cava.nix +++ b/modules/programs/tui/cava.nix @@ -1,5 +1,5 @@ {self, ...}: { - flake.modules.homeManager.cava = _: { + flake.modules.homeManager.cava = { imports = [self.modules.homeManager.stylixBase]; programs.cava = { diff --git a/modules/programs/tui/neovim/components/autocomplete.nix b/modules/programs/tui/neovim/components/autocomplete.nix index 58ea14c..63d734d 100644 --- a/modules/programs/tui/neovim/components/autocomplete.nix +++ b/modules/programs/tui/neovim/components/autocomplete.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.neovim = _: { + flake.modules.homeManager.neovim = { programs.nvf.settings.vim.autocomplete.blink-cmp = { enable = true; friendly-snippets.enable = true; diff --git a/modules/programs/tui/neovim/components/biscuits.nix b/modules/programs/tui/neovim/components/biscuits.nix index 2832f80..b97b482 100644 --- a/modules/programs/tui/neovim/components/biscuits.nix +++ b/modules/programs/tui/neovim/components/biscuits.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.neovim = _: { + flake.modules.homeManager.neovim = { programs.nvf.settings.vim.utility.nvim-biscuits = { enable = true; diff --git a/modules/programs/tui/neovim/components/breadcrumbs.nix b/modules/programs/tui/neovim/components/breadcrumbs.nix index 2e15aa6..28b74a0 100644 --- a/modules/programs/tui/neovim/components/breadcrumbs.nix +++ b/modules/programs/tui/neovim/components/breadcrumbs.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.neovim = _: { + flake.modules.homeManager.neovim = { programs.nvf.settings.vim.visuals.dropbar-nvim = { enable = true; }; diff --git a/modules/programs/tui/neovim/components/cheatsheet.nix b/modules/programs/tui/neovim/components/cheatsheet.nix index e04ca59..c12de9b 100644 --- a/modules/programs/tui/neovim/components/cheatsheet.nix +++ b/modules/programs/tui/neovim/components/cheatsheet.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.neovim = _: { + flake.modules.homeManager.neovim = { programs.nvf.settings.vim = { # keep-sorted start block=yes newline_separated=yes binds = { diff --git a/modules/programs/tui/neovim/components/dim.nix b/modules/programs/tui/neovim/components/dim.nix index 9610a8c..ff535a1 100644 --- a/modules/programs/tui/neovim/components/dim.nix +++ b/modules/programs/tui/neovim/components/dim.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.neovim = _: { + flake.modules.homeManager.neovim = { programs.nvf.settings.vim = { keymaps = [ { diff --git a/modules/programs/tui/neovim/components/git.nix b/modules/programs/tui/neovim/components/git.nix index d6a51ff..0d2019d 100644 --- a/modules/programs/tui/neovim/components/git.nix +++ b/modules/programs/tui/neovim/components/git.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.neovim = _: { + flake.modules.homeManager.neovim = { programs.nvf.settings.vim.git = { # keep-sorted start block=yes newline_separated=yes git-conflict.enable = true; diff --git a/modules/programs/tui/neovim/components/hardtime.nix b/modules/programs/tui/neovim/components/hardtime.nix index a32e5f8..0df2d2c 100644 --- a/modules/programs/tui/neovim/components/hardtime.nix +++ b/modules/programs/tui/neovim/components/hardtime.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.neovim = _: { + flake.modules.homeManager.neovim = { programs.nvf.settings.vim.binds.hardtime-nvim = { enable = true; diff --git a/modules/programs/tui/neovim/components/highlight.nix b/modules/programs/tui/neovim/components/highlight.nix index a061ce4..4cf4505 100644 --- a/modules/programs/tui/neovim/components/highlight.nix +++ b/modules/programs/tui/neovim/components/highlight.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.neovim = _: { + flake.modules.homeManager.neovim = { programs.nvf.settings.vim.ui.colorizer = { enable = true; diff --git a/modules/programs/tui/neovim/components/indent.nix b/modules/programs/tui/neovim/components/indent.nix index 95d2543..a5315b6 100644 --- a/modules/programs/tui/neovim/components/indent.nix +++ b/modules/programs/tui/neovim/components/indent.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.neovim = _: { + flake.modules.homeManager.neovim = { programs.nvf.settings.vim = { # Enable proper indentation across languages. utility = { diff --git a/modules/programs/tui/neovim/components/presence.nix b/modules/programs/tui/neovim/components/presence.nix index 7d2dab4..b7c880b 100644 --- a/modules/programs/tui/neovim/components/presence.nix +++ b/modules/programs/tui/neovim/components/presence.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.neovim = _: { + flake.modules.homeManager.neovim = { # Discord rich presence via cord.nvim. programs.nvf.settings.vim.presence.cord-nvim = { enable = true; diff --git a/modules/programs/tui/neovim/components/profiler.nix b/modules/programs/tui/neovim/components/profiler.nix index 5eb5981..7ac01d5 100644 --- a/modules/programs/tui/neovim/components/profiler.nix +++ b/modules/programs/tui/neovim/components/profiler.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.neovim = _: { + flake.modules.homeManager.neovim = { programs.nvf.settings.vim = { # keep-sorted start block=yes newline_separated=yes keymaps = [ diff --git a/modules/programs/tui/neovim/components/scroll.nix b/modules/programs/tui/neovim/components/scroll.nix index 701d13d..d63f7bc 100644 --- a/modules/programs/tui/neovim/components/scroll.nix +++ b/modules/programs/tui/neovim/components/scroll.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.neovim = _: { + flake.modules.homeManager.neovim = { programs.nvf.settings.vim.utility.snacks-nvim.setupOpts.scroll = { enable = true; diff --git a/modules/programs/tui/neovim/components/scrollbar.nix b/modules/programs/tui/neovim/components/scrollbar.nix index a4d01ca..63524d8 100644 --- a/modules/programs/tui/neovim/components/scrollbar.nix +++ b/modules/programs/tui/neovim/components/scrollbar.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.neovim = _: { + flake.modules.homeManager.neovim = { # Add satellite.nvim scrollbar indicators. programs.nvf.settings.vim.visuals.satellite-nvim = { enable = true; diff --git a/modules/programs/tui/neovim/keymap.nix b/modules/programs/tui/neovim/keymap.nix index 5fa8aa1..c51226d 100644 --- a/modules/programs/tui/neovim/keymap.nix +++ b/modules/programs/tui/neovim/keymap.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.neovim = _: { + flake.modules.homeManager.neovim = { programs.nvf.settings.vim = { keymaps = [ # keep-sorted start block=yes newline_separated=yes diff --git a/modules/programs/tui/neovim/languages/css.nix b/modules/programs/tui/neovim/languages/css.nix index 7520c54..4f8b5a9 100644 --- a/modules/programs/tui/neovim/languages/css.nix +++ b/modules/programs/tui/neovim/languages/css.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.neovim = _: { + flake.modules.homeManager.neovim = { programs.nvf.settings.vim = { languages.css = { enable = true; diff --git a/modules/programs/tui/neovim/languages/default.nix b/modules/programs/tui/neovim/languages/default.nix index 8beaa1a..86633e8 100644 --- a/modules/programs/tui/neovim/languages/default.nix +++ b/modules/programs/tui/neovim/languages/default.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.neovim = _: { + flake.modules.homeManager.neovim = { programs.nvf.settings.vim.languages = { # keep-sorted start enableExtraDiagnostics = true; diff --git a/modules/programs/tui/neovim/languages/docker.nix b/modules/programs/tui/neovim/languages/docker.nix index afb33c3..b558488 100644 --- a/modules/programs/tui/neovim/languages/docker.nix +++ b/modules/programs/tui/neovim/languages/docker.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.neovim = _: { + flake.modules.homeManager.neovim = { programs.nvf.settings.vim.languages.docker = { enable = true; extraDiagnostics.enable = true; diff --git a/modules/programs/tui/neovim/languages/lua.nix b/modules/programs/tui/neovim/languages/lua.nix index d77f32b..18be57b 100644 --- a/modules/programs/tui/neovim/languages/lua.nix +++ b/modules/programs/tui/neovim/languages/lua.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.neovim = _: { + flake.modules.homeManager.neovim = { programs.nvf.settings.vim.languages.lua = { enable = true; extraDiagnostics.types = ["selene"]; diff --git a/modules/programs/tui/neovim/languages/markdown.nix b/modules/programs/tui/neovim/languages/markdown.nix index 908fade..4c19b7c 100644 --- a/modules/programs/tui/neovim/languages/markdown.nix +++ b/modules/programs/tui/neovim/languages/markdown.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.neovim = _: { + flake.modules.homeManager.neovim = { programs.nvf.settings.vim = { # keep-sorted start block=yes newline_separated=yes # Add a shortcut to toggle markview rendering. diff --git a/modules/programs/tui/neovim/languages/nix.nix b/modules/programs/tui/neovim/languages/nix.nix index 483affd..d5d1af0 100644 --- a/modules/programs/tui/neovim/languages/nix.nix +++ b/modules/programs/tui/neovim/languages/nix.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.neovim = _: { + flake.modules.homeManager.neovim = { programs.nvf.settings.vim.languages.nix = { enable = true; diff --git a/modules/programs/tui/neovim/languages/other.nix b/modules/programs/tui/neovim/languages/other.nix index b6b82e9..31c55e0 100644 --- a/modules/programs/tui/neovim/languages/other.nix +++ b/modules/programs/tui/neovim/languages/other.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.neovim = _: { + flake.modules.homeManager.neovim = { programs.nvf.settings.vim.languages = { # keep-sorted start bash.enable = true; diff --git a/modules/programs/tui/neovim/languages/python.nix b/modules/programs/tui/neovim/languages/python.nix index f4bbd59..9577819 100644 --- a/modules/programs/tui/neovim/languages/python.nix +++ b/modules/programs/tui/neovim/languages/python.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.neovim = _: { + flake.modules.homeManager.neovim = { programs.nvf.settings.vim.languages.python = { enable = true; format.type = ["ruff"]; diff --git a/modules/programs/tui/neovim/languages/rust.nix b/modules/programs/tui/neovim/languages/rust.nix index ceb5f8a..27a9715 100644 --- a/modules/programs/tui/neovim/languages/rust.nix +++ b/modules/programs/tui/neovim/languages/rust.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.neovim = _: { + flake.modules.homeManager.neovim = { programs.nvf.settings.vim.languages.rust = { enable = true; diff --git a/modules/programs/tui/neovim/languages/toml.nix b/modules/programs/tui/neovim/languages/toml.nix index 961b415..87c0635 100644 --- a/modules/programs/tui/neovim/languages/toml.nix +++ b/modules/programs/tui/neovim/languages/toml.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.neovim = _: { + flake.modules.homeManager.neovim = { programs.nvf.settings.vim.languages.toml = { enable = true; format.type = ["tombi"]; diff --git a/modules/programs/tui/neovim/languages/typescript.nix b/modules/programs/tui/neovim/languages/typescript.nix index 76c8627..5003ce3 100644 --- a/modules/programs/tui/neovim/languages/typescript.nix +++ b/modules/programs/tui/neovim/languages/typescript.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.neovim = _: { + flake.modules.homeManager.neovim = { programs.nvf.settings.vim.languages.typescript = { enable = true; format.type = ["biome"]; diff --git a/modules/programs/tui/opencode/theme.nix b/modules/programs/tui/opencode/theme.nix index 1a4cdac..54a491d 100644 --- a/modules/programs/tui/opencode/theme.nix +++ b/modules/programs/tui/opencode/theme.nix @@ -1,5 +1,5 @@ {self, ...}: { - flake.modules.homeManager.opencode = _: { + flake.modules.homeManager.opencode = { imports = [self.modules.homeManager.stylixBase]; # Keep the opencode background transparent to match stylix. diff --git a/modules/programs/tui/television/default.nix b/modules/programs/tui/television/default.nix index 7810f18..8453fd5 100644 --- a/modules/programs/tui/television/default.nix +++ b/modules/programs/tui/television/default.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.television = _: { + flake.modules.homeManager.television = { programs.television = let # Disable shell hooks and use explicit invocation only. enableShellIntegration = false; diff --git a/modules/programs/tui/television/settings.nix b/modules/programs/tui/television/settings.nix index 112c93a..c1a3967 100644 --- a/modules/programs/tui/television/settings.nix +++ b/modules/programs/tui/television/settings.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.television = _: { + flake.modules.homeManager.television = { programs.television.settings = let # Use minimal box borders to match the rest of the terminal theme. borderType = "plain"; diff --git a/modules/programs/tui/yazi/default.nix b/modules/programs/tui/yazi/default.nix index 998a2da..c26fcc7 100644 --- a/modules/programs/tui/yazi/default.nix +++ b/modules/programs/tui/yazi/default.nix @@ -1,5 +1,5 @@ {self, ...}: { - flake.modules.homeManager.yazi = _: { + flake.modules.homeManager.yazi = { imports = [self.modules.homeManager.git]; # Yazi tui file manager. diff --git a/modules/programs/tui/yazi/keymap.nix b/modules/programs/tui/yazi/keymap.nix index db95abe..d00cb4a 100644 --- a/modules/programs/tui/yazi/keymap.nix +++ b/modules/programs/tui/yazi/keymap.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.yazi = _: { + flake.modules.homeManager.yazi = { programs.yazi.keymap.mgr.prepend_keymap = [ { on = "!"; diff --git a/modules/programs/tui/yazi/settings.nix b/modules/programs/tui/yazi/settings.nix index 9724b9f..7c96077 100644 --- a/modules/programs/tui/yazi/settings.nix +++ b/modules/programs/tui/yazi/settings.nix @@ -1,5 +1,5 @@ { - flake.modules.homeManager.yazi = _: let + flake.modules.homeManager.yazi = let # Memory allocation for image previews in megabytes. imageAllocMB = 1024; in { diff --git a/modules/programs/tui/yazi/theme.nix b/modules/programs/tui/yazi/theme.nix index 0b102ee..97cb6f9 100644 --- a/modules/programs/tui/yazi/theme.nix +++ b/modules/programs/tui/yazi/theme.nix @@ -1,42 +1,42 @@ { - flake.modules.homeManager.yazi = _: - # Remove rounded corners. - { - programs.yazi.theme = { - # keep-sorted start block=yes newline_separated=yes - indicator.padding = { - open = "█"; - close = "█"; - }; - - status = { + flake.modules.homeManager.yazi = + # Remove rounded corners. + { + programs.yazi.theme = { # keep-sorted start block=yes newline_separated=yes - sep_left = { - open = ""; - close = ""; + indicator.padding = { + open = "█"; + close = "█"; }; - sep_right = { - open = ""; - close = ""; - }; - # keep-sorted end - }; + status = { + # keep-sorted start block=yes newline_separated=yes + sep_left = { + open = ""; + close = ""; + }; - tabs = { - # keep-sorted start block=yes newline_separated=yes - sep_inner = { - open = ""; - close = ""; + sep_right = { + open = ""; + close = ""; + }; + # keep-sorted end }; - sep_outer = { - open = ""; - close = ""; + tabs = { + # keep-sorted start block=yes newline_separated=yes + sep_inner = { + open = ""; + close = ""; + }; + + sep_outer = { + open = ""; + close = ""; + }; + # keep-sorted end }; # keep-sorted end }; - # keep-sorted end }; - }; } diff --git a/modules/services/flatpak.nix b/modules/services/flatpak.nix index d5f2acf..aaa0a8c 100644 --- a/modules/services/flatpak.nix +++ b/modules/services/flatpak.nix @@ -1,7 +1,7 @@ {inputs, ...}: { flake-file.inputs.nix-flatpak.url = "github:gmodena/nix-flatpak"; - flake.modules.nixos.flatpak = _: { + flake.modules.nixos.flatpak = { services.flatpak.enable = true; };