kak: clear inlays after buffer is modified

This commit is contained in:
Leonardo Eugênio 2022-12-06 09:18:24 -03:00 committed by lelgenio
parent 9b8ae4400b
commit 767b8289ee

View file

@ -76,6 +76,16 @@ plug 'kak-lsp/kak-lsp' do %{
hook -once -always window WinSetOption filetype=.* %{
remove-hooks window semantic-tokens
}
decl -hidden -docstring "Timestamp of the last check" int last_modified
hook window RawKey .* %{
eval %sh{
if [ "${kak_opt_last_modified}" != "${kak_timestamp}" ]; then
echo "unset-option buffer lsp_inlay_diagnostics"
echo "unset-option buffer lsp_inlay_hints"
fi
}
set current last_modified %val{timestamp}
}
}
declare-option -hidden str modeline_progress ""