diff --git a/modules/services/dunst.nix b/modules/services/dunst.nix index 0e82d43b6..0a5daf381 100644 --- a/modules/services/dunst.nix +++ b/modules/services/dunst.nix @@ -155,7 +155,17 @@ in } (mkIf (cfg.settings != {}) { - xdg.configFile."dunst/dunstrc".text = toDunstIni cfg.settings; + xdg.configFile."dunst/dunstrc" = { + text = toDunstIni cfg.settings; + onChange = '' + pkillVerbose="" + if [[ -v VERBOSE ]]; then + pkillVerbose="-e" + fi + $DRY_RUN_CMD ${pkgs.procps}/bin/pkill -u $USER $pkillVerbose dunst + unset pkillVerbose + ''; + }; }) ] );