From 8f311cc4bafd07a1d35bb225bbdfff806242245d Mon Sep 17 00:00:00 2001 From: Doloro1978 Date: Mon, 29 Jun 2026 23:30:19 +0100 Subject: [PATCH] meow --- config/hosts/aspects/doloro-desktop/home.nix | 11 +- config/hosts/aspects/doloro-desktop/host.nix | 15 ++- config/modules/nikpkgs.nix | 4 +- config/modules/nixvim/default.nix | 22 ++-- config/modules/obs.nix | 125 ++++++++++--------- flake.lock | 122 +++++++++--------- 6 files changed, 159 insertions(+), 140 deletions(-) diff --git a/config/hosts/aspects/doloro-desktop/home.nix b/config/hosts/aspects/doloro-desktop/home.nix index 0e01fc0..7ccaa32 100644 --- a/config/hosts/aspects/doloro-desktop/home.nix +++ b/config/hosts/aspects/doloro-desktop/home.nix @@ -52,13 +52,16 @@ users.users.doloro = { shell = pkgs.fish; hashedPasswordFile = config.sops.secrets."doloro-hashed_password".path; - extraGroups = [ "libvirtd" ]; + extraGroups = [ + "libvirtd" + "gamemode" + ]; }; - virtualisation.libvirtd.enable = true; + virtualisation.libvirtd.enable = false; # virtualisation.waydroid.enable = true; # # Newer kernel versions may need # virtualisation.waydroid.package = pkgs.waydroid-nftables; - programs.virt-manager.enable = true; + programs.virt-manager.enable = false; }; homeManager = { @@ -76,7 +79,7 @@ "hyprctl dispatch workspace 2" # shit solution to get quickshell on the right monitor ]; workspace = [ - "name:2, monitor:DP-3" + "name:2, monitor:DP-2" ]; input = { kb_layout = "gb"; diff --git a/config/hosts/aspects/doloro-desktop/host.nix b/config/hosts/aspects/doloro-desktop/host.nix index 2b60d9a..2cdd2ed 100644 --- a/config/hosts/aspects/doloro-desktop/host.nix +++ b/config/hosts/aspects/doloro-desktop/host.nix @@ -30,7 +30,7 @@ boot.loader.grub.efiInstallAsRemovable = true; networking.hostName = "doloroo-main"; # Define your hostname. - # boot.kernelPackages = pkgs.linuxPackages_latest; + boot.kernelPackages = pkgs.linuxPackages_latest; boot.initrd.verbose = false; boot.kernelParams = [ @@ -95,6 +95,13 @@ # Optionally, you may need to select the appropriate driver version for your specific GPU. package = config.boot.kernelPackages.nvidiaPackages.stable; }; + swapDevices = [ + { + device = "/swapfile"; + size = 8192; + } + ]; + boot.binfmt.emulatedSystems = [ "aarch64-linux" ]; @@ -106,6 +113,12 @@ SCX_SCHEDULER_OVERRIDE = "scx_lavd"; SCX_FLAGS_OVERRIDE = "--performance --no-core-compaction"; }; + systemd.oomd = { + enable = true; + enableUserSlices = true; + enableRootSlice = true; + enableSystemSlice = true; + }; }; }; } diff --git a/config/modules/nikpkgs.nix b/config/modules/nikpkgs.nix index ccb7e62..4b520e5 100644 --- a/config/modules/nikpkgs.nix +++ b/config/modules/nikpkgs.nix @@ -6,8 +6,8 @@ }: { flake-file.inputs = { nik-pkgs = { - url = "git+https://git.scug.io/nikkuss/pkgs.git"; - # inputs.nixpkgs.follows = "nixpkgs"; + url = "git+https://git.scug.io/nikkuss/pkgs.git?ref=main"; + inputs.nixpkgs.follows = "nixpkgs"; }; }; modules.nikpkgs = { diff --git a/config/modules/nixvim/default.nix b/config/modules/nixvim/default.nix index 41e3fea..58643c2 100644 --- a/config/modules/nixvim/default.nix +++ b/config/modules/nixvim/default.nix @@ -10,7 +10,7 @@ flake-file.inputs = { nixvim = { url = "github:nix-community/nixvim"; - # inputs.nixpkgs.follows = "nixpkgs"; + inputs.nixpkgs.follows = "nixpkgs"; }; }; modules = { @@ -23,18 +23,18 @@ { pkgs, ... }: let # REPLACE THIS ONCE ITS FIXED IN UPSTREAM - cssLsFixed = pkgs.vscode-langservers-extracted.overrideAttrs (old: { - postInstall = (old.postInstall or "") + '' - sed -i 's/import\.meta\.url/"file:\/\/"+__filename/g' \ - $out/lib/node_modules/vscode-langservers-extracted/lib/css-language-server/node/cssServerMain.js - ''; - }); + # cssLsFixed = pkgs.vscode-langservers-extracted.overrideAttrs (old: { + # postInstall = (old.postInstall or "") + '' + # sed -i 's/import\.meta\.url/"file:\/\/"+__filename/g' \ + # $out/lib/node_modules/vscode-langservers-extracted/lib/css-language-server/node/cssServerMain.js + # ''; + # }); tiny-code-action = pkgs.vimUtils.buildVimPlugin { name = "tiny-code-action.nvim"; src = pkgs.fetchFromGitHub { owner = "rachartier"; repo = "tiny-code-action.nvim"; - rev = "main"; + rev = "0d040ed81f7953118b81cd12681fcdfcac069803"; hash = "sha256-UF9zeO5Uujdt2MEwy2d2Lhk6JRnEN4vrEvYslv0/zaA"; }; nvimSkipModules = [ "tiny-code-action.previewers.snacks" ]; @@ -51,7 +51,7 @@ config = { allowUnfree = true; }; - # source = pkgs; + # source = inputs.nixpkgs; }; colorschemes.gruvbox-material.enable = true; # colorschemes.melange = { @@ -141,14 +141,14 @@ }; }; astro = { - enable = true; + enable = false; }; ts_ls = { enable = true; }; cssls = { enable = true; - package = cssLsFixed; + # package = cssLsFixed; }; svelte.enable = true; }; diff --git a/config/modules/obs.nix b/config/modules/obs.nix index 0e15592..114bae6 100644 --- a/config/modules/obs.nix +++ b/config/modules/obs.nix @@ -2,71 +2,74 @@ den, modules, ... -}: { +}: +{ modules.obs = settings: { - homeManager = { - pkgs, - lib, - config, - ... - }: { - programs = { - obs-studio = { - enable = true; - package = ( - pkgs.obs-studio.override { - cudaSupport = true; - } - ); - plugins = with pkgs.obs-studio-plugins; [ - obs-pipewire-audio-capture - obs-vkcapture - obs-vaapi #optional AMD hardware acceleration - obs-gstreamer - ]; - }; - }; - systemd.user.services = let - audio-set = lib.mkIf settings.audio { - pw-discordaudio-virtual-device = { - Unit = { - Description = "OBS daemon"; - After = ["hyprland-session.target"]; - }; - Install = { - WantedBy = ["default.target"]; - }; - Service = { - ExecStart = "${pkgs.writeShellScript "discord_audio_virt_device" '' - pw-loopback -m '[ FL FR]' --capture-props='media.class=Audio/Sink node.name=DiscordSink' -n DiscordSink - ''}"; - Restart = "on-failure"; - RestartSec = "5s"; - }; - }; - pw-gameaudio-virtual-device = { - Unit = { - Description = "OBS daemon"; - After = ["hyprland-session.target"]; - }; - Install = { - WantedBy = ["default.target"]; - }; - Service = { - ExecStart = "${pkgs.writeShellScript "game_audio_virt_device" '' - pw-loopback -m '[ FL FR]' --capture-props='media.class=Audio/Sink node.name=GameAudioSink' -n GameAudioSink - ''}"; - Restart = "on-failure"; - RestartSec = "5s"; - }; + homeManager = + { + pkgs, + lib, + config, + ... + }: + { + programs = { + obs-studio = { + enable = true; + package = ( + pkgs.obs-studio.override { + cudaSupport = true; + } + ); + plugins = with pkgs.obs-studio-plugins; [ + obs-pipewire-audio-capture + obs-vkcapture + obs-gstreamer + ]; }; }; - in - lib.mergeAttrsList [audio-set]; + systemd.user.services = + let + audio-set = lib.mkIf settings.audio { + pw-discordaudio-virtual-device = { + Unit = { + Description = "OBS daemon"; + After = [ "hyprland-session.target" ]; + }; + Install = { + WantedBy = [ "default.target" ]; + }; + Service = { + ExecStart = "${pkgs.writeShellScript "discord_audio_virt_device" '' + pw-loopback -m '[ FL FR]' --capture-props='media.class=Audio/Sink node.name=DiscordSink' -n DiscordSink + ''}"; + Restart = "on-failure"; + RestartSec = "5s"; + }; + }; + pw-gameaudio-virtual-device = { + Unit = { + Description = "OBS daemon"; + After = [ "hyprland-session.target" ]; + }; + Install = { + WantedBy = [ "default.target" ]; + }; + Service = { + ExecStart = "${pkgs.writeShellScript "game_audio_virt_device" '' + pw-loopback -m '[ FL FR]' --capture-props='media.class=Audio/Sink node.name=GameAudioSink' -n GameAudioSink + ''}"; + Restart = "on-failure"; + RestartSec = "5s"; + }; + }; + }; + in + lib.mergeAttrsList [ audio-set ]; - wayland.windowManager.hyprland.settings = { - # exec-once = ["${config.programs.obs-studio.finalPackage}/bin/obs --startreplaybuffer"]; + wayland.windowManager.hyprland.settings = { + # exec-once = ["${config.programs.obs-studio.finalPackage}/bin/obs --startreplaybuffer"]; + }; }; - }; }; } diff --git a/flake.lock b/flake.lock index 12d4260..a4eb4ee 100644 --- a/flake.lock +++ b/flake.lock @@ -20,11 +20,11 @@ ] }, "locked": { - "lastModified": 1780756231, - "narHash": "sha256-tXQxKdG5716uB9/LIkLQqQwHKf5mRSpHoZhz3lyI2Cg=", + "lastModified": 1782073106, + "narHash": "sha256-dnS5SaZlPqR1E0dPXaPc+lFkBwLUbAgbwsVMk7uA6dY=", "owner": "hyprwm", "repo": "aquamarine", - "rev": "6ecde03f47172753fe5a2f334f9d3facfb7e6784", + "rev": "6d6e2384f381def4ea4ea81543cba4bbdac72457", "type": "github" }, "original": { @@ -497,11 +497,11 @@ "utils": "utils" }, "locked": { - "lastModified": 1782474838, - "narHash": "sha256-TUFVwwTofzuxJiHx/xXa7jqVkVIwreOYH47YxhmCHEo=", + "lastModified": 1782532589, + "narHash": "sha256-SbRcgRa3CYE0UWW+Zbbgih4amUqYKCaFQe/v3H4380U=", "owner": "vikingnope", "repo": "helium-browser-nix-flake", - "rev": "849135b2ce70edc2edfb8865e7d839c8297a545e", + "rev": "66082f4d174c15ff00b25a20bbd593255fce6d35", "type": "github" }, "original": { @@ -517,11 +517,11 @@ ] }, "locked": { - "lastModified": 1782423922, - "narHash": "sha256-qPNd6lUohHP5gcJhqQ7rLV87RwIx0xYR2A4Frb9Zjc4=", + "lastModified": 1782702263, + "narHash": "sha256-8/MG4Su7PhnynrmsVO61IeAfrK7GuUEu+E+gwbhy1QQ=", "owner": "nix-community", "repo": "home-manager", - "rev": "5d320ab301cfaaca7d32514f13815d19d109f5f4", + "rev": "789a35fbdeb3c46b260096daa0b321c11be527ea", "type": "github" }, "original": { @@ -575,11 +575,11 @@ ] }, "locked": { - "lastModified": 1776426399, - "narHash": "sha256-RUESLKNikIeEq9ymGJ6nmcDXiSFQpUW1IhJ245nL3xM=", + "lastModified": 1782566056, + "narHash": "sha256-haEZcHzYrePnjFOYSWTbxm/Nrla0aPslJfmvdCvqtVc=", "owner": "hyprwm", "repo": "hyprgraphics", - "rev": "68d064434787cf1ed4a2fe257c03c5f52f33cf84", + "rev": "c6e7b9f673f4360bc813d3dc75028f75ee88d3f8", "type": "github" }, "original": { @@ -605,11 +605,11 @@ "xdph": "xdph" }, "locked": { - "lastModified": 1782468408, - "narHash": "sha256-es78EqYsT2+21M+jRdMY063EqEk8wL+mwSYyOOPECLI=", + "lastModified": 1782658834, + "narHash": "sha256-OYjcMSNogYWLbeP4nxpUVJaO72o6yIK00bDYaAuQI2Y=", "owner": "hyprwm", "repo": "Hyprland", - "rev": "afe2c390ab621e7a1dbd06744d33bc123acfe1f9", + "rev": "75f558a536f8003bf80af5cb1a3e91529e78cb6b", "type": "github" }, "original": { @@ -651,11 +651,11 @@ ] }, "locked": { - "lastModified": 1776426575, - "narHash": "sha256-KI6nIfVihn/DPaeB5Et46Xg3dkNHrrEtUd5LBBVomB0=", + "lastModified": 1782563850, + "narHash": "sha256-rs/EzgrgPHbCtJjFZN4aR1HYldH/0NtGAempWVpWQTs=", "owner": "hyprwm", "repo": "hyprland-guiutils", - "rev": "a968d211048e3ed538e47b84cb3649299578f19d", + "rev": "5ba080ee036c30cb2485f2647ff8a61f7aa08178", "type": "github" }, "original": { @@ -757,11 +757,11 @@ ] }, "locked": { - "lastModified": 1772462885, - "narHash": "sha256-5pHXrQK9zasMnIo6yME6EOXmWGFMSnCITcfKshhKJ9I=", + "lastModified": 1782554491, + "narHash": "sha256-+p3MlyN/nqRefcf2IckPlGRUn9+hielqpS9XClbLleM=", "owner": "hyprwm", "repo": "hyprtoolkit", - "rev": "9af245a69fa6b286b88ddfc340afd288e00a6998", + "rev": "bdba25ced39ea39ab004a8f31593ba0b0ff1ca35", "type": "github" }, "original": { @@ -782,11 +782,11 @@ ] }, "locked": { - "lastModified": 1780251518, - "narHash": "sha256-fG9xbb1SOAAJ+2kJRakp3ch+BmA/3dEg/K3PoAZTKkw=", + "lastModified": 1782035033, + "narHash": "sha256-pUtCphVzH1iNUTMGdJr4+e/yzUXA6/DZwsn+cyfIVJU=", "owner": "hyprwm", "repo": "hyprutils", - "rev": "40ede2e7bdec80ba5d4c443160d905e9f841ae5f", + "rev": "9d8bf6e810597152eef8906c670b96679af2faec", "type": "github" }, "original": { @@ -929,11 +929,11 @@ "xwayland-satellite-unstable": "xwayland-satellite-unstable" }, "locked": { - "lastModified": 1782472066, - "narHash": "sha256-VMCzcdi7U7obVGgP5D5wsr5EqwxAB9bp1ZqS3WOaxsM=", + "lastModified": 1782592242, + "narHash": "sha256-kgINba6Ilpj3rdTi2BeKlQBs6ZxTdu3Gb49U5gDUVhg=", "owner": "sodiboo", "repo": "niri-flake", - "rev": "3b2f591f1e32d681867e4416c2559e719a4756d8", + "rev": "9e26dfe0fb8d61475b6f9e8d63477fe92509f1db", "type": "github" }, "original": { @@ -1019,11 +1019,11 @@ "nixpkgs": "nixpkgs_7" }, "locked": { - "lastModified": 1782379505, - "narHash": "sha256-zPvPiU+a7pqtH47xrtZLNRABJKpOjfZQclDbcvNtH+I=", + "lastModified": 1782562157, + "narHash": "sha256-a7+T6QSeowynwZ1ZJJbP8T8ntAytvrui8kFGJmIZt2c=", "owner": "NixOS", "repo": "nixos-hardware", - "rev": "603d3afd1b6145bd66e97ae38a34d91c95df70cf", + "rev": "a9cf7546a938c737b079e738de73934a13de9784", "type": "github" }, "original": { @@ -1133,11 +1133,11 @@ }, "nixpkgs-stable": { "locked": { - "lastModified": 1782335603, - "narHash": "sha256-sZkQH1CkiZtdvcaLx4sGQD9Q9h+A8qB04DRpqQCN530=", + "lastModified": 1782498288, + "narHash": "sha256-8/X3yyTXiE82b38n32ItbOqfWOVBl+gKa8fILyZfR4Q=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "03c72920da828594fae523aaef96f33dff10b340", + "rev": "3cac626ec5e3703e835f227687e88aa9e2f25701", "type": "github" }, "original": { @@ -1149,11 +1149,11 @@ }, "nixpkgs_10": { "locked": { - "lastModified": 1781577229, - "narHash": "sha256-lrp67w8AulE9Ks53n27I45ADSzbOCn4H+CNW1Ck8B+8=", + "lastModified": 1782467914, + "narHash": "sha256-pGvFkM8N0xEkIIXDe5YYfbEAvHrk4IxBrjB/x8OomhE=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "567a49d1913ce81ac6e9582e3553dd90a955875f", + "rev": "e73de5be04e0eff4190a1432b946d469c794e7b4", "type": "github" }, "original": { @@ -1213,11 +1213,11 @@ }, "nixpkgs_14": { "locked": { - "lastModified": 1781577229, - "narHash": "sha256-rcUHdUtJEvMdNEl2Wq+YpHraHKfcer3KsBscpZEF2Yg=", - "rev": "567a49d1913ce81ac6e9582e3553dd90a955875f", + "lastModified": 1782467914, + "narHash": "sha256-inDx/w70OSJoJPqtKh0BrzAsbZZhpya7YgS43jHnhwg=", + "rev": "e73de5be04e0eff4190a1432b946d469c794e7b4", "type": "tarball", - "url": "https://releases.nixos.org/nixos/unstable/nixos-26.11pre1017464.567a49d1913c/nixexprs.tar.xz" + "url": "https://releases.nixos.org/nixos/unstable/nixos-26.11pre1022855.e73de5be04e0/nixexprs.tar.xz" }, "original": { "type": "tarball", @@ -1255,11 +1255,11 @@ }, "nixpkgs_4": { "locked": { - "lastModified": 1780749050, - "narHash": "sha256-3av0pIjlOWQ6rDbNOmpUSvbNnJkGORQKKjb4LtCZsIY=", + "lastModified": 1782467914, + "narHash": "sha256-pGvFkM8N0xEkIIXDe5YYfbEAvHrk4IxBrjB/x8OomhE=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "a799d3e3886da994fa307f817a6bc705ae538eeb", + "rev": "e73de5be04e0eff4190a1432b946d469c794e7b4", "type": "github" }, "original": { @@ -1353,11 +1353,11 @@ "systems": "systems_4" }, "locked": { - "lastModified": 1782254890, - "narHash": "sha256-kjsEECqhpPnJWqhooXp6tWh2qGQftCPAo2G1GvZtKdw=", + "lastModified": 1782706849, + "narHash": "sha256-b2ODGxKD3hgrwuesLtDomp2DKF3UiOn3+EBTDXpcqGo=", "owner": "nix-community", "repo": "nixvim", - "rev": "dbf9550dba8448b03e11d58e5695d6c44a464554", + "rev": "c6a99bb41fb0f37e03ca38b1d81b006e98e3bf1a", "type": "github" }, "original": { @@ -1420,11 +1420,11 @@ ] }, "locked": { - "lastModified": 1778507602, - "narHash": "sha256-kTwur1wV+01SdqskVMSo6JMEpg71ps3HpbFY2GsflKs=", + "lastModified": 1781733627, + "narHash": "sha256-U3yTuGBnmXvXoQI3qkpfEDsn9RovQPAjN7ndRco+3u0=", "owner": "cachix", "repo": "git-hooks.nix", - "rev": "61ab0e80d9c7ab14c256b5b453d8b3fb0189ba0a", + "rev": "3bbec39bc90eadfa031e6f3b77272f3f60803e39", "type": "github" }, "original": { @@ -1599,11 +1599,11 @@ "systems": "systems_5" }, "locked": { - "lastModified": 1782031037, - "narHash": "sha256-a7oWSyS7SN81UOqVt481yIEMDsMpaJ7GNdV6Eaz5Yqg=", + "lastModified": 1782633406, + "narHash": "sha256-JOSMk12GgnTLVlUSCuKkqyUF6cw82wl7t7e1WuFfg5s=", "owner": "Gerg-L", "repo": "spicetify-nix", - "rev": "9cb27462cfd20edac174353f1e95bc03aa888863", + "rev": "5ff9a6ca9dcbad7cccea2c97d30237468b16feda", "type": "github" }, "original": { @@ -1632,11 +1632,11 @@ "tinted-zed": "tinted-zed" }, "locked": { - "lastModified": 1782310521, - "narHash": "sha256-vsxcG0i8e4EPfdnhMTKMVzD1825H2vG1BBslzom9wxg=", + "lastModified": 1782658900, + "narHash": "sha256-/s51VbBRGLH1NSjJ3AGhOGG8BXH/Jo+5JWMmaa2n+Jk=", "owner": "nix-community", "repo": "stylix", - "rev": "e084d011e7ee9302aceaaf6c1fc28a9ace09e16a", + "rev": "1fbdd38c16645731b2bdc4f70170765f725a3735", "type": "github" }, "original": { @@ -1882,11 +1882,11 @@ ] }, "locked": { - "lastModified": 1780133819, - "narHash": "sha256-0YPKIY3dlnR7SPq7Z8ekFVvzFsfeiAtEj+QUI3KHrlI=", + "lastModified": 1782311043, + "narHash": "sha256-07zLc2M3/ax+JsjxGTft17/Joua41LHE9/9AC/F9zeU=", "owner": "hyprwm", "repo": "xdg-desktop-portal-hyprland", - "rev": "4a170c0ba96fd37374f93d8f91c9ed91814828ac", + "rev": "882ad01e195ce201b07c618bbee44a0cad8b9e5a", "type": "github" }, "original": { @@ -1935,11 +1935,11 @@ ] }, "locked": { - "lastModified": 1781847955, - "narHash": "sha256-1OSYOGuJp/NoODmSHjsz+6TB/kSilJ+BsFihjY7TTnc=", + "lastModified": 1782624757, + "narHash": "sha256-pqFaCAV+g8H+p0kE4vYn9ZgcEFvt644zGy7SyCdf9c8=", "owner": "youwen5", "repo": "zen-browser-flake", - "rev": "4bca251cd556677f7b765ff324d1638ae215be13", + "rev": "907465791e7064d86d37964dd95e23280dfb68da", "type": "github" }, "original": {