From 9defb280e1d0b4161e3e829e1900360383ff3583 Mon Sep 17 00:00:00 2001 From: Kate Adkins Date: Wed, 27 Nov 2024 16:04:34 -0700 Subject: [PATCH] valere: update things for KDE'd setup --- flake.lock | 24 ++++++------- nixos/configs/gui/default.nix | 15 ++++---- nixos/configs/gui/niri.nix | 5 +++ nixos/configs/gui/waybar/default.nix | 2 +- nixos/dotfiles/talon.hm.nix | 5 +++ nixos/hosts/valere/default.nix | 54 ++++++++++++++-------------- wezterm/wezterm.lua | 2 +- 7 files changed, 58 insertions(+), 49 deletions(-) diff --git a/flake.lock b/flake.lock index ecc6215..bd36f47 100644 --- a/flake.lock +++ b/flake.lock @@ -51,11 +51,11 @@ "fromYaml": "fromYaml" }, "locked": { - "lastModified": 1708890466, - "narHash": "sha256-LlrC09LoPi8OPYOGPXegD72v+//VapgAqhbOFS3i8sc=", + "lastModified": 1732200724, + "narHash": "sha256-+R1BH5wHhfnycySb7Sy5KbYEaTJZWm1h+LW1OtyhiTs=", "owner": "SenchoPens", "repo": "base16.nix", - "rev": "665b3c6748534eb766c777298721cece9453fdae", + "rev": "153d52373b0fb2d343592871009a286ec8837aec", "type": "github" }, "original": { @@ -360,11 +360,11 @@ "fromYaml": { "flake": false, "locked": { - "lastModified": 1689549921, - "narHash": "sha256-iX0pk/uB019TdBGlaJEWvBCfydT6sRq+eDcGPifVsCM=", + "lastModified": 1731966426, + "narHash": "sha256-lq95WydhbUTWig/JpqiB7oViTcHFP8Lv41IGtayokA8=", "owner": "SenchoPens", "repo": "fromYaml", - "rev": "11fbbbfb32e3289d3c631e0134a23854e7865c84", + "rev": "106af9e2f715e2d828df706c386a685698f3223b", "type": "github" }, "original": { @@ -440,11 +440,11 @@ ] }, "locked": { - "lastModified": 1724435763, - "narHash": "sha256-UNky3lJNGQtUEXT2OY8gMxejakSWPTfWKvpFkpFlAfM=", + "lastModified": 1730837930, + "narHash": "sha256-0kZL4m+bKBJUBQse0HanewWO0g8hDdCvBhudzxgehqc=", "owner": "nix-community", "repo": "home-manager", - "rev": "c2cd2a52e02f1dfa1c88f95abeb89298d46023be", + "rev": "2f607e07f3ac7e53541120536708e824acccfaa8", "type": "github" }, "original": { @@ -1075,11 +1075,11 @@ "tinted-tmux": "tinted-tmux" }, "locked": { - "lastModified": 1731657386, - "narHash": "sha256-Mm/JL8tFUS1SOmmZDPcswExUxzw0VpHcEyZI1h58CGA=", + "lastModified": 1732261424, + "narHash": "sha256-8uTKUHkaU980J5kRnLYrdwmjZYB88eBGUk1oVgIUHFE=", "owner": "danth", "repo": "stylix", - "rev": "5ab1207b2fdeb5a022f2dd7cccf6be760f1b150f", + "rev": "b667a340730dd3d0596083aa7c949eef01367c62", "type": "github" }, "original": { diff --git a/nixos/configs/gui/default.nix b/nixos/configs/gui/default.nix index 98cb8e2..acee595 100644 --- a/nixos/configs/gui/default.nix +++ b/nixos/configs/gui/default.nix @@ -35,13 +35,6 @@ ) ]; - # Also provide an xserver and plasma, for when we need accessibility. - services.xserver.enable = true; - services.desktopManager.plasma6.enable = true; - - # Don't let Plasma override TLP with PPD. - services.power-profiles-daemon.enable = lib.mkForce false; - # Enable espanso, when possible. services.espanso.enable = true; @@ -143,14 +136,18 @@ sddm = { enable = true; autoNumlock = true; - #wayland.enable = true; - #theme = "chili"; + wayland.enable = true; }; }; # Use KDE connect. programs.kdeconnect.enable = true; + # Also enable plasma, for when we need to use X11 for e.g. Talon. + services.xserver.enable = true; + services.desktopManager.plasma6.enable = true; + services.power-profiles-daemon.enable = lib.mkForce false; + # Enable sound with pipewire. hardware.pulseaudio.enable = false; security.rtkit.enable = true; diff --git a/nixos/configs/gui/niri.nix b/nixos/configs/gui/niri.nix index 922abf1..3dff38b 100644 --- a/nixos/configs/gui/niri.nix +++ b/nixos/configs/gui/niri.nix @@ -179,6 +179,11 @@ in default-column-width = { }; } + # Talon windows should show over other ones. + { + matches = [ { app-id = "talon"; } ]; + } + # Bitwig needs to set its own width. { matches = [ { app-id = "^com.bitwig.BitwigStudio$"; } ]; diff --git a/nixos/configs/gui/waybar/default.nix b/nixos/configs/gui/waybar/default.nix index 5a8c6be..c687595 100644 --- a/nixos/configs/gui/waybar/default.nix +++ b/nixos/configs/gui/waybar/default.nix @@ -193,7 +193,7 @@ in # programs.waybar = { enable = true; - systemd.enable = true; + #systemd.enable = true; # Replace the package with a patched one. package = pkgs.waybar.overrideAttrs (prev: { diff --git a/nixos/dotfiles/talon.hm.nix b/nixos/dotfiles/talon.hm.nix index 577eee0..200e63a 100644 --- a/nixos/dotfiles/talon.hm.nix +++ b/nixos/dotfiles/talon.hm.nix @@ -1,6 +1,8 @@ { pkgs, ... }: { # talon configuration + # note: this *must* be recursive instead of one big link, + # since talon wants to stick files in here, too home.file.".talon/user" = { source = ../../talon; recursive = true; @@ -28,6 +30,9 @@ base=/home/deprekated/.talon/core unset QT_AUTO_SCREEN_SCALE_FACTOR QT_SCALE_FACTOR + # Make sure this knows how to access our display. + DISPLAY=:0 + ${pkgs.steam-run}/bin/steam-run env LC_NUMERIC=C QT_PLUGIN_PATH="$base/lib/plugins" LD_LIBRARY_PATH="$base/lib:$base/resources/python/lib:$base/resources/pypy/lib" "$base/talon" "$@" ''; }; diff --git a/nixos/hosts/valere/default.nix b/nixos/hosts/valere/default.nix index a5ed9b7..90a9c35 100644 --- a/nixos/hosts/valere/default.nix +++ b/nixos/hosts/valere/default.nix @@ -49,38 +49,40 @@ # # Intel+NVIDIA / prime setup. # - - services.xserver.videoDrivers = [ "nvidia" ]; - - # Set up the NVIDIA half of the GPU setup. - # These are used only in the "enabled" configuration. + # Provide a configuration that uses the full GPU power of the system. system.nixos.tags = [ "Intel" ]; - hardware.nvidia = { - modesetting.enable = true; - - # Prefer the open NVIDIA driver. - open = true; - - # Enable the nvidia-settings command. - nvidiaSettings = true; - - # Offloading setup: use GPU when asked for by command, and not otherwise. - prime = { - sync.enable = true; - - # Specify how to find our GPUs. - intelBusId = "PCI:0:2:0"; - nvidiaBusId = "PCI:1:0:0"; - }; - - }; # Disable the NVIDIA GPU unless we explicitly request it. hardware.nvidiaOptimus.disable = true; - # Provide a configuration that uses the full GPU power of the system. specialisation.optimus.configuration = { - system.nixos.tags = lib.mkForce [ "NVIDIA" ]; + system.nixos.tags = [ "NVIDIA" ]; + services.xserver.videoDrivers = [ "nvidia" ]; + + # Set up the NVIDIA half of the GPU setup. + # These are used only in the "enabled" configuration. + hardware.nvidia = { + modesetting.enable = true; + + # Prefer the open NVIDIA driver. + open = true; + + # Enable the nvidia-settings command. + nvidiaSettings = true; + + # Offloading setup: use GPU when asked for by command, and not otherwise. + prime = { + sync.enable = true; + + # Specify how to find our GPUs. + intelBusId = "PCI:0:2:0"; + nvidiaBusId = "PCI:1:0:0"; + }; + + }; + + # Include the NVIDIA X11. + boot.extraModulePackages = [ config.boot.kernelPackages.nvidia_x11 ]; # Don't disable optimus on this config. hardware.nvidiaOptimus.disable = lib.mkForce false; diff --git a/wezterm/wezterm.lua b/wezterm/wezterm.lua index 85c312d..d50a37d 100644 --- a/wezterm/wezterm.lua +++ b/wezterm/wezterm.lua @@ -208,7 +208,7 @@ config = { font_overrides = { miko = 10, hinata = 16, - valere = 12, + valere = 10, utol = 13, trailblazer = 12, kanbaru = 12,