diff --git a/settings/hyprland.nix b/settings/hyprland.nix index 9d7e217..5fdfa43 100644 --- a/settings/hyprland.nix +++ b/settings/hyprland.nix @@ -201,6 +201,9 @@ in extraConfig = let powerMenu = pkgs.writeShellScript "power-menu" '' + # Kill the daemon before using anyrun in standalone stdin mode; + # a concurrent standalone instance conflicts with the daemon. + ${pkgs.anyrun}/bin/anyrun quit 2>/dev/null || true choice=$(printf '%s\n' \ $'\uf023 Lock' \ $'\uf08b Logout' \ @@ -211,6 +214,8 @@ in --show-results-immediately true \ --hide-plugin-info true \ --close-on-click true) + # Restart the daemon for instant launcher opens. + ${pkgs.anyrun}/bin/anyrun daemon & case "$choice" in *Lock) ${pkgs.hyprlock}/bin/hyprlock ;; *Logout) hyprctl dispatch exit ;;