From e60fd01ba3a77a24fa86b39928fcc58ab2888b34 Mon Sep 17 00:00:00 2001 From: Doloro1978 Date: Thu, 25 Sep 2025 15:45:57 +0100 Subject: [PATCH] commit --- hypr/hyprland.conf | 1 + nix/home.nix | 32 ++++++++++++++++++++++++++++--- nix/modules/hyprland/settings.nix | 3 ++- nix/modules/obs/home.nix | 16 ++++++++++++++++ nix/modules/steam/nixos.nix | 3 +-- nix/overlays.nix | 16 ++++++++++++++++ nvim/init.lua | 2 +- 7 files changed, 66 insertions(+), 7 deletions(-) create mode 100644 nix/modules/obs/home.nix create mode 100644 nix/overlays.nix diff --git a/hypr/hyprland.conf b/hypr/hyprland.conf index 9d76bf0..2cefa3a 100755 --- a/hypr/hyprland.conf +++ b/hypr/hyprland.conf @@ -319,6 +319,7 @@ windowrule = suppressevent maximize, class:.* # Gamescope / games on workspace 5 windowrule = workspace 5 silent, class:^(gamescope)$ +windowrule = # Gamescope tearing windowrule = immediate, class:^(gamescope)$ diff --git a/nix/home.nix b/nix/home.nix index bb67f6a..91de650 100644 --- a/nix/home.nix +++ b/nix/home.nix @@ -1,4 +1,4 @@ -{ inputs, config, pkgs, ... }: +{ inputs, config, pkgs, fetchFromGitHub, ... }: { imports = [ @@ -11,6 +11,8 @@ ./modules/tmux/home.nix ./modules/theme/home.nix ./modules/spicetify/home.nix + ./modules/obs/home.nix + ./overlays.nix ]; # Home Manager needs a bit of information about you and the paths it should # manage. @@ -81,9 +83,33 @@ dunst = { enable = true; }; + arrpc = { + enable = true; + package = pkgs.arrpc; + }; }; - - + systemd.user.services.pw-discordaudio-virtual-device = { + Install = { + WantedBy = [ "hyprland-session.target" ]; + }; + Service = { + ExecStart = "${pkgs.writeShellScript "discord_audio_virt_device" '' + #!/run/current-system/sw/bin/bash + pw-loopback -m '[ FL FR]' --capture-props='media.class=Audio/Sink node.name=DiscordSink' -n DiscordSink + ''}"; + }; + }; + systemd.user.services.pw-gameaudio-virtual-device = { + Install = { + WantedBy = [ "hyprland-session.target" ]; + }; + Service = { + ExecStart = "${pkgs.writeShellScript "game_audio_virt_device" '' + #!/run/current-system/sw/bin/bash + pw-loopback -m '[ FL FR]' --capture-props='media.class=Audio/Sink node.name=GameAudioSink' -n GameAudioSink + ''}"; + }; + }; # Let Home Manager install and manage itself. programs.home-manager.enable = true; } diff --git a/nix/modules/hyprland/settings.nix b/nix/modules/hyprland/settings.nix index dfd47b5..2eec93e 100644 --- a/nix/modules/hyprland/settings.nix +++ b/nix/modules/hyprland/settings.nix @@ -126,7 +126,8 @@ ]; windowrule = [ "suppressevent maximize, class:.*" - "workspace 5 silent, class:^(gamescope)$" + "workspace 5, class:^(gamescope)$" + "fullscreen, class:^(gamescope)$" "immediate, class:^(gamescope)$" "workspace 6 silent, class:^(steam)$" "workspace 8 silent, class:^(vesktop)$" diff --git a/nix/modules/obs/home.nix b/nix/modules/obs/home.nix new file mode 100644 index 0000000..497e0df --- /dev/null +++ b/nix/modules/obs/home.nix @@ -0,0 +1,16 @@ +{ inputs, pkgs, ... }: { + programs = { + obs-studio = { + enable = true; + package = ( + pkgs.obs-studio.override { + cudaSupport = true; + } + ); + plugins = with pkgs.obs-studio-plugins; [ + obs-pipewire-audio-capture + obs-vkcapture + ]; + }; +}; +} diff --git a/nix/modules/steam/nixos.nix b/nix/modules/steam/nixos.nix index 4059983..7df0b3f 100644 --- a/nix/modules/steam/nixos.nix +++ b/nix/modules/steam/nixos.nix @@ -29,8 +29,7 @@ keyutils mangohud gamemode - (gamescope.overrideAttrs { enableWsi = true; }) - + (gamescope.overrideAttrs { enableWsi = true; NIX_CFLAGS_COMPILE = ["-fno-fast-math"]; }) ]; }; }; diff --git a/nix/overlays.nix b/nix/overlays.nix new file mode 100644 index 0000000..c1deb8b --- /dev/null +++ b/nix/overlays.nix @@ -0,0 +1,16 @@ +{ pkgs, lib, ... }: +let + arrpc_overlay = (self: super: { + arrpc = super.arrpc.overrideAttrs (prev: { + version = "git"; + src = pkgs.fetchFromGitHub { + owner = "Doloro1978"; + repo = "arrpc"; + tag = "tag3"; + sha256 = "sha256-9Tnw/BmIAA+RPAfhHFv0kenrRdoxJuUw3iRjKykGxdE="; + }; + }); + }); +in { + nixpkgs.overlays = [ arrpc_overlay ]; +} diff --git a/nvim/init.lua b/nvim/init.lua index e9fc628..3277cff 120000 --- a/nvim/init.lua +++ b/nvim/init.lua @@ -1 +1 @@ -/nix/store/pgyxzk4kwmbs72sgg51bfqpn2304brq6-home-manager-files/.config/nvim/init.lua \ No newline at end of file +/nix/store/w3hgd2jyhil85jbrhr0bahb8pgmlnzj6-home-manager-files/.config/nvim/init.lua \ No newline at end of file