From 3d150f601dae74cee3ccce75de124d844eee0d41 Mon Sep 17 00:00:00 2001 From: Stzx Date: Tue, 1 Oct 2024 12:04:28 +0800 Subject: [PATCH] waybar: support enable inspect from service --- modules/programs/waybar.nix | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/modules/programs/waybar.nix b/modules/programs/waybar.nix index 72d247323..9e485d621 100644 --- a/modules/programs/waybar.nix +++ b/modules/programs/waybar.nix @@ -209,6 +209,17 @@ in { ''; }; + systemd.enableInspect = mkOption { + type = bool; + default = false; + example = true; + description = '' + Inspect objects and find their CSS classes, experiment with live CSS styles, and lookup the current value of CSS properties. + + See + ''; + }; + style = mkOption { type = nullOr (either path lines); default = null; @@ -317,6 +328,8 @@ in { ExecReload = "${pkgs.coreutils}/bin/kill -SIGUSR2 $MAINPID"; Restart = "on-failure"; KillMode = "mixed"; + } // optionalAttrs cfg.systemd.enableInspect { + Environment = [ "GTK_DEBUG=interactive" ]; }; Install = { WantedBy = [ cfg.systemd.target ]; };