summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartin Bielik <mx.bielik@gmail.com>2023-05-05 11:46:04 +0200
committerGitHub <noreply@github.com>2023-05-05 11:46:04 +0200
commit2a2ef1b6d9115f2ba72bd88c3663cb7670379374 (patch)
tree4d23faf53388f104c741dc46702da3efc9ccb46a
parent38225a94fc393a4d4e98c48d1a09168b67d7d3ff (diff)
parentbd512e69c87a44f091b00fd12a4a044fdf6e3330 (diff)
downloadvim-ai-2a2ef1b6d9115f2ba72bd88c3663cb7670379374.tar.gz
Merge pull request #30 from BonaBeavis/patch-1
Allow single undo
-rw-r--r--py/utils.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/py/utils.py b/py/utils.py
index dc86f34..01315ef 100644
--- a/py/utils.py
+++ b/py/utils.py
@@ -44,6 +44,7 @@ def render_text_chunks(chunks):
continue # trim newlines from the beginning
generating_text = True
vim.command("normal! a" + text)
+ vim.command("undojoin")
vim.command("redraw")
full_text += text
if not full_text.strip():