From 210e4bb81fa22f7b69d1a4fed57b7790f501d0d9 Mon Sep 17 00:00:00 2001 From: twoneis Date: Sun, 30 Jun 2024 16:08:52 +0200 Subject: [PATCH] added plasma but doesn't work --- modules/home/default.nix | 4 +- modules/home/plasma/default.nix | 128 +++++++++++++++++++++++++++++++- 2 files changed, 128 insertions(+), 4 deletions(-) diff --git a/modules/home/default.nix b/modules/home/default.nix index e5d5a20..a971616 100644 --- a/modules/home/default.nix +++ b/modules/home/default.nix @@ -19,7 +19,9 @@ in { home-manager = { useGlobalPkgs = true; useUserPackages = true; - sharedModules = [ inputs.plasma-manager.homeManagerModules.plasma-manager ]; + sharedModules = with inputs; [ + plasma-manager.homeManagerModules.plasma-manager + ]; users.twoneis = { imports = [ diff --git a/modules/home/plasma/default.nix b/modules/home/plasma/default.nix index 6684a94..0cca881 100644 --- a/modules/home/plasma/default.nix +++ b/modules/home/plasma/default.nix @@ -1,5 +1,127 @@ -{ ... }: { - programs.plasma = { - enable = true; +{ pkgs, ... }: { +programs.plasma = { + enable = true; + + workspace = { + clickItemTo = "open"; # If you liked the click-to-open default from plasma 5 + lookAndFeel = "org.kde.breezedark.desktop"; + cursor = { + theme = "Bibata-Modern-Ice"; + size = 32; + }; + iconTheme = "Papirus-Dark"; + wallpaper = "${pkgs.kdePackages.plasma-workspace-wallpapers}/share/wallpapers/Patak/contents/images/1080x1920.png"; + }; + + hotkeys.commands."launch-konsole" = { + name = "Launch Konsole"; + key = "Meta+Alt+K"; + command = "konsole"; + }; + + fonts = { + general = { + family = "JetBrains Mono"; + pointSize = 12; + }; + }; + + panels = [ + # Windows-like panel at the bottom + { + location = "bottom"; + widgets = [ + { + name = "org.kde.plasma.kickoff"; + config = { + General.icon = "nix-snowflake-white"; + }; + } + { + name = "org.kde.plasma.icontasks"; + config = { + General.launchers = [ + "applications:org.kde.dolphin.desktop" + "applications:org.kde.konsole.desktop" + ]; + }; + } + "org.kde.plasma.marginsseparator" + { + digitalClock = { + calendar.firstDayOfWeek = "sunday"; + time.format = "12h"; + }; + } + { + systemTray.items = { + shown = [ + "org.kde.plasma.battery" + "org.kde.plasma.bluetooth" + ]; + hidden = [ + "org.kde.plasma.networkmanagement" + "org.kde.plasma.volume" + ]; + }; + } + ]; + hiding = "autohide"; + } + { + location = "top"; + height = 26; + widgets = [ + "org.kde.plasma.appmenu" + ]; + } + ]; + + window-rules = [ + { + description = "Dolphin"; + match = { + window-class = { + value = "dolphin"; + type = "substring"; + }; + window-types = [ "normal" ]; + }; + apply = { + noborder = { + value = true; + apply = "force"; + }; + maximizehoriz = true; + maximizevert = true; + }; + } + ]; + shortcuts = { + ksmserver = { + "Lock Session" = [ "Screensaver" "Meta+Ctrl+Alt+L" ]; + }; + + kwin = { + "Expose" = "Meta+,"; + "Switch Window Down" = "Meta+J"; + "Switch Window Left" = "Meta+H"; + "Switch Window Right" = "Meta+L"; + "Switch Window Up" = "Meta+K"; + }; + }; + + configFile = { + baloofilerc."Basic Settings"."Indexing-Enabled" = false; + kwinrc."org.kde.kdecoration2".ButtonsOnLeft = "SF"; + kwinrc.Desktops.Number = { + value = 8; + immutable = true; + }; + kscreenlockerrc = { + Greeter.WallpaperPlugin = "org.kde.potd"; + "Greeter/Wallpaper/org.kde.potd/General".Provider = "bing"; + }; + }; }; }