From 12d6960e198cf5107aed84a4b21e95c826d43dad Mon Sep 17 00:00:00 2001 From: Artem Timofeev <39891735+atimofeev@users.noreply.github.com> Date: Sun, 25 May 2025 22:10:13 +0200 Subject: [PATCH] feat(nixos): enabled systemd service, removed deprecation notice (#943) Closes #892 Co-authored-by: Jas Singh --- nix/module.nix | 36 +++++++++++++++++------------------- 1 file changed, 17 insertions(+), 19 deletions(-) diff --git a/nix/module.nix b/nix/module.nix index 1c5932f..c835982 100644 --- a/nix/module.nix +++ b/nix/module.nix @@ -723,25 +723,23 @@ in text = finalConfig; }; - # NOTE: Deprecated - # systemd.user.services = mkIf cfg.systemd.enable { - # hyprpanel = { - # Unit = { - # Description = "A Bar/Panel for Hyprland with extensive customizability."; - # Documentation = "https://hyprpanel.com"; - # PartOf = [ "graphical-session.target" ]; - # After = [ "graphical-session-pre.target" ]; - # }; - # Service = { - # ExecStart = "${package}/bin/hyprpanel"; - # ExecReload = "${pkgs.coreutils}/bin/kill -SIGUSR1 $MAINPID"; - # Restart = "on-failure"; - # KillMode = "mixed"; - # }; - # Install = { WantedBy = [ "graphical-session.target" ]; }; - # }; - # }; - warnings = if cfg.systemd.enable then [ "The `systemd.enable` option is now obsolete." ] else [ ]; + systemd.user.services = mkIf cfg.systemd.enable { + hyprpanel = { + Unit = { + Description = "A Bar/Panel for Hyprland with extensive customizability."; + Documentation = "https://hyprpanel.com"; + PartOf = [ "graphical-session.target" ]; + After = [ "graphical-session-pre.target" ]; + }; + Service = { + ExecStart = "${package}/bin/hyprpanel"; + ExecReload = "${pkgs.coreutils}/bin/kill -SIGUSR1 $MAINPID"; + Restart = "on-failure"; + KillMode = "mixed"; + }; + Install = { WantedBy = [ "graphical-session.target" ]; }; + }; + }; wayland.windowManager.hyprland.settings.exec-once = mkIf cfg.hyprland.enable [ "${package}/bin/hyprpanel"