From a9104c7cc32d10178d679dbf53baad575d1ceb0b Mon Sep 17 00:00:00 2001 From: "Alexandre Cavalheiro S. Tiago da Silva" Date: Fri, 20 Sep 2024 11:52:36 -0300 Subject: [PATCH 1/3] fix(kdeconnect): use a kdeconnect that ships kdeconnectd --- modules/nixos/packages.nix | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/modules/nixos/packages.nix b/modules/nixos/packages.nix index 0eee06e..b4c1ded 100644 --- a/modules/nixos/packages.nix +++ b/modules/nixos/packages.nix @@ -29,7 +29,10 @@ }; # Enable KDEConnect - programs.kdeconnect.enable = true; + programs.kdeconnect = { + enable = true; + package = pkgs.kdePackages.kdeconnect-kde; + }; # Enable Docker. virtualisation.docker.enable = true; From 186f879b73d8a4a319d8ee2199502cc961b2fb36 Mon Sep 17 00:00:00 2001 From: "Alexandre Cavalheiro S. Tiago da Silva" Date: Fri, 20 Sep 2024 11:54:50 -0300 Subject: [PATCH 2/3] feat(authentication): move to kde auth agents and services As well as move the script to common.nix where we can point the correct binary for the polkit agent --- modules/home-manager/common.nix | 65 +++++++++++++++++++ .../scripts/hyprland/start_services.sh | 48 -------------- specific/desktop/services/authentication.nix | 10 +-- 3 files changed, 70 insertions(+), 53 deletions(-) delete mode 100755 modules/home-manager/scripts/hyprland/start_services.sh diff --git a/modules/home-manager/common.nix b/modules/home-manager/common.nix index 13f8dfe..4600d9d 100644 --- a/modules/home-manager/common.nix +++ b/modules/home-manager/common.nix @@ -70,6 +70,71 @@ source = ./scripts; recursive = true; }; + + ".local/share/scripts/hyprland/start_services.sh" = { + executable = true; + text = # sh + '' + #!/bin/sh + + # + # Make sure xdg-desktop-portal-hyprland has access to what it needs + # + dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP & + + # + # Start waybar. + # + waybar & + + # + # Start xwaylandvideobridge + # + xwaylandvideobridge & + + + # + # Start wallpaper daemon + # + ~/.local/share/scripts/wallpaper.sh & + + # + # Start notification daemon. + # + mako & + + # + # Start polkit agent + # + ${pkgs.libsForQt5.polkit-kde-agent}/libexec/polkit-kde-authentication-agent-1 + + # + # Start kwallet service + # + kwalletd6 & + + # + # Start kdeconnect daemon + # + kdeconnectd & + + # + # Clipboard manager + # + wl-paste --type text --watch cliphist store & + wl-paste --type image --watch cliphist store & + + # + # Start Fcitx5 + # + fcitx5 & + + # + # Start the blueman applet for managing bluetooth devices + # + blueman-applet & + ''; + }; }; # Configure XDG diff --git a/modules/home-manager/scripts/hyprland/start_services.sh b/modules/home-manager/scripts/hyprland/start_services.sh deleted file mode 100755 index 59c3a09..0000000 --- a/modules/home-manager/scripts/hyprland/start_services.sh +++ /dev/null @@ -1,48 +0,0 @@ -#!/bin/sh - -# -# Make sure xdg-desktop-portal-hyprland has access to what it needs -# -dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP & - -# -# Start waybar. -# -waybar & - -# -# Start xwaylandvideobridge -# -xwaylandvideobridge & - - -# -# Start wallpaper daemon -# -~/.local/share/scripts/wallpaper.sh & - -# -# Start notification daemon. -# -mako & - -# -# Refresh kdeconnect connections -# -kdeconnect-cli --refresh & - -# -# Clipboard manager -# -wl-paste --type text --watch cliphist store & -wl-paste --type image --watch cliphist store & - -# -# Start Fcitx5 -# -fcitx5 & - -# -# Start the blueman applet for managing bluetooth devices -# -blueman-applet & diff --git a/specific/desktop/services/authentication.nix b/specific/desktop/services/authentication.nix index 94797f5..64a2b2c 100644 --- a/specific/desktop/services/authentication.nix +++ b/specific/desktop/services/authentication.nix @@ -4,9 +4,9 @@ # Enable polkit, security.polkit.enable = true; - # Install an agent to interface with it. - environment.systemPackages = with pkgs; [ polkit_gnome ]; - - # And enable GNOME keyring for registering keys. - services.gnome.gnome-keyring.enable = true; + # Install a keyring service and manager. + environment.systemPackages = with pkgs; [ + libsForQt5.kwallet + libsForQt5.kwalletmanager + ]; } From 5e9fa217f20b77e90e360dc8115151eda255a9c8 Mon Sep 17 00:00:00 2001 From: "Alexandre Cavalheiro S. Tiago da Silva" Date: Fri, 20 Sep 2024 11:55:36 -0300 Subject: [PATCH 3/3] fix(waybar): adjust icons for the new font --- modules/home-manager/programs/waybar.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/modules/home-manager/programs/waybar.nix b/modules/home-manager/programs/waybar.nix index aeeeab2..6328603 100644 --- a/modules/home-manager/programs/waybar.nix +++ b/modules/home-manager/programs/waybar.nix @@ -69,18 +69,18 @@ memory = { interval = 5; - format = " {percentage}%"; + format = " {percentage}%"; states = { warning = 70; critical = 90; }; - "tooltip-format" = " {used:0.1f}G/{total:0.1f}G"; + "tooltip-format" = " {used:0.1f}G/{total:0.1f}G"; }; cpu = { interval = 5; tooltip = false; - format = " {usage}%"; + format = " {usage}%"; format-alt = " {load}"; states = { warning = 70;