From 32426d61c3bd2dcfecfabbe3ca97c5edd8f1e9a1 Mon Sep 17 00:00:00 2001 From: pagedown Date: Wed, 30 Mar 2022 20:49:48 +0800 Subject: [PATCH] Shell integration: Mark fish prompt on cancel or syntax error The fish_prompt event will not be fired, even if a new prompt has been drawn. --- .../fish/vendor_conf.d/kitty-shell-integration.fish | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/shell-integration/fish/vendor_conf.d/kitty-shell-integration.fish b/shell-integration/fish/vendor_conf.d/kitty-shell-integration.fish index 2cde01347..02d4f95b7 100644 --- a/shell-integration/fish/vendor_conf.d/kitty-shell-integration.fish +++ b/shell-integration/fish/vendor_conf.d/kitty-shell-integration.fish @@ -72,7 +72,7 @@ function __ksi_schedule --on-event fish_prompt -d "Setup kitty integration after # Enable prompt marking with OSC 133 if not contains "no-prompt-mark" $_ksi and not set -q __ksi_prompt_state - function __ksi_mark_prompt_start --on-event fish_prompt + function __ksi_mark_prompt_start --on-event fish_prompt --on-event fish_cancel --on-event fish_posterror test "$__ksi_prompt_state" != prompt-start and echo -en "\e]133;D\a" set --global __ksi_prompt_state prompt-start