From b1d0134ab95699839d9a6d68c845782b3fc2af4b Mon Sep 17 00:00:00 2001 From: 844196 <844196@users.noreply.github.com> Date: Sun, 20 Jul 2025 16:54:47 +0900 Subject: [PATCH] :boom: Insert at cursor position without replacing buffer --- src/widget.eta | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/widget.eta b/src/widget.eta index 0816424..f72eadd 100644 --- a/src/widget.eta +++ b/src/widget.eta @@ -31,9 +31,9 @@ _wk_widget() { reply=("${(@ps:\t:)res}") if [[ "${reply[(rb:2:)eval:*]}" == 'eval:true' ]]; then - BUFFER=${(e)reply[1]} + BUFFER="${LBUFFER}${(e)reply[1]}${RBUFFER}" else - BUFFER=${reply[1]} + BUFFER="${LBUFFER}${reply[1]}${RBUFFER}" fi CURSOR=${#BUFFER}