Skip to content

Commit

Permalink
waybar: add systemd restart triggers
Browse files Browse the repository at this point in the history
  • Loading branch information
rycee authored Dec 22, 2024
1 parent f47b6c1 commit cb27edb
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion modules/programs/waybar.nix
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,8 @@

let
inherit (lib)
all filterAttrs hasAttr isStorePath literalExpression optionalAttrs types;
all filterAttrs hasAttr isStorePath literalExpression optional optionalAttrs
types;
inherit (lib.options) mkEnableOption mkOption;
inherit (lib.modules) mkIf mkMerge;

Expand Down Expand Up @@ -310,6 +311,10 @@ in {
Documentation = "https://github.com/Alexays/Waybar/wiki";
PartOf = [ "graphical-session.target" ];
After = [ "graphical-session-pre.target" ];
X-Restart-Triggers = optional (settings != [ ])
"${config.xdg.configFile."waybar/config".source}"
++ optional (cfg.style != null)
"${config.xdg.configFile."waybar/style.css".source}";
};

Service = {
Expand Down

0 comments on commit cb27edb

Please sign in to comment.