From bcf32b384c690903c6d4c7a1e3bbcc1f9e964eb3 Mon Sep 17 00:00:00 2001 From: albert Date: Tue, 24 Sep 2024 21:58:47 +0900 Subject: [PATCH] Update Plasma --- flake.nix | 4 ++-- .../common/desktops/plasma6/default.nix | 3 ++- .../desktops/plasma6/plasma-manager.nix | 10 ++-------- nixos/common/desktops/plasma6/default.nix | 2 ++ .../themes/gruvbox/home-manager/plasma6.nix | 20 +++++++++++++++++++ 5 files changed, 28 insertions(+), 11 deletions(-) create mode 100644 stylix/themes/gruvbox/home-manager/plasma6.nix diff --git a/flake.nix b/flake.nix index 03e7a317..2bab77fa 100644 --- a/flake.nix +++ b/flake.nix @@ -63,7 +63,7 @@ # User Machines nixos-desktop = libx.mkHost { hostname = "nixos-desktop"; unfree = true; desktop = "plasma6"; theme = "gruvbox"; }; nixos-framework = libx.mkHost { hostname = "nixos-framework"; unfree = true; desktop = "plasma6"; theme = "gruvbox"; }; - steamdeck = libx.mkDeck { hostname = "steamdeck"; desktop = "plasma6"; theme = "gruvbox"; }; + steamdeck = libx.mkDeck { hostname = "steamdeck"; desktop = "plasma6"; }; # Raspberry Pi's backups-rpi4 = libx.mkHost { hostname = "backups-rpi4"; system = "aarch64-linux"; type = "small"; }; @@ -85,7 +85,7 @@ # User Machines "albert@nixos-desktop" = libx.mkHome { hostname = "nixos-desktop"; desktop = "plasma6"; theme = "gruvbox"; }; "albert@nixos-framework" = libx.mkHome { hostname = "nixos-framework"; desktop = "plasma6"; theme = "gruvbox"; }; - "albert@steamdeck" = libx.mkHome { hostname = "steamdeck"; desktop = "plasma6"; theme = "gruvbox"; }; + "albert@steamdeck" = libx.mkHome { hostname = "steamdeck"; desktop = "plasma6"; }; # Raspberry Pi's "albert@backups-rpi4" = libx.mkHome { hostname = "backups-rpi4"; system = "aarch64-linux"; type = "small"; }; diff --git a/home-manager/common/desktops/plasma6/default.nix b/home-manager/common/desktops/plasma6/default.nix index a6753504..3d43450c 100644 --- a/home-manager/common/desktops/plasma6/default.nix +++ b/home-manager/common/desktops/plasma6/default.nix @@ -1,6 +1,7 @@ -{ inputs, pkgs, ... }: { +{ inputs, theme, ... }: { imports = [ inputs.plasma-manager.homeManagerModules.plasma-manager + ../../../../stylix/themes/${theme}/home-manager/plasma6.nix ./plasma-manager.nix ]; diff --git a/home-manager/common/desktops/plasma6/plasma-manager.nix b/home-manager/common/desktops/plasma6/plasma-manager.nix index 64cffd71..ebdba283 100644 --- a/home-manager/common/desktops/plasma6/plasma-manager.nix +++ b/home-manager/common/desktops/plasma6/plasma-manager.nix @@ -26,12 +26,6 @@ }; }; - kdeglobals = { - General = { - accentColorFromWallpaper = true; - }; - }; - kwinrc = { # Set window border size "org.kde.kdecoration2" = { @@ -61,7 +55,6 @@ workspace = { clickItemTo = "select"; - # iconTheme = "Breeze"; wallpaper = "/etc/nixos/git/wallpapers/${theme}/wallpaper1.png"; theme = "Arc-Dark"; colorScheme = "Arc"; @@ -78,7 +71,8 @@ { name = "org.kde.plasma.kicker"; config = { - General.icon = "nix-snowflake-white"; + General.icon = "draw-circle"; + # General.icon = "nix-snowflake-white"; }; } { diff --git a/nixos/common/desktops/plasma6/default.nix b/nixos/common/desktops/plasma6/default.nix index 4392e8ed..23796788 100644 --- a/nixos/common/desktops/plasma6/default.nix +++ b/nixos/common/desktops/plasma6/default.nix @@ -28,6 +28,8 @@ kdePackages.kleopatra # GPG GUI kdePackages.krdc # K Remote Desktop kdePackages.kasts # Podcast player + kde-gruvbox + gruvbox-gtk-theme # Audio button workaround # plasma-pa diff --git a/stylix/themes/gruvbox/home-manager/plasma6.nix b/stylix/themes/gruvbox/home-manager/plasma6.nix new file mode 100644 index 00000000..333f788c --- /dev/null +++ b/stylix/themes/gruvbox/home-manager/plasma6.nix @@ -0,0 +1,20 @@ +{ lib, ... }: { + programs.bash.sessionVariables = { + GTK_THEME = lib.mkForce "Gruvbox-Dark"; # To set the firefox theme + }; + programs.fish.shellInit = lib.mkForce '' + set GTK_THEME "Gruvbox-Dark" + ''; + services.darkman = { + darkModeScripts = { + apply-colorscheme-dark = lib.mkForce '' + /run/current-system/sw/bin/plasma-apply-colorscheme Gruvbox + ''; + }; + lightModeScripts = { + apply-colorscheme-light = lib.mkForce '' + /run/current-system/sw/bin/plasma-apply-colorscheme BreezeLight + ''; + }; + }; +}