From 44c011c5988077b515204159b6930c69c0475571 Mon Sep 17 00:00:00 2001 From: Raymaekers Luca Date: Tue, 25 Jun 2024 01:10:02 +0200 Subject: checkpoint --- config/essentials/zsh/widgets.zsh | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) (limited to 'config/essentials/zsh/widgets.zsh') diff --git a/config/essentials/zsh/widgets.zsh b/config/essentials/zsh/widgets.zsh index 233ea65..cce9fbc 100644 --- a/config/essentials/zsh/widgets.zsh +++ b/config/essentials/zsh/widgets.zsh @@ -1,8 +1,7 @@ # Surround line in variable -surround_in_var() -{ - BUFFER=" \"\$($BUFFER)\"" - zle beginning-of-line +surround_in_var() { + BUFFER=" \"\$($BUFFER)\"" + zle beginning-of-line } zle -N surround_in_var bindkey '\ev' surround_in_var @@ -10,9 +9,7 @@ bindkey '\ev' surround_in_var # Insert output from the previous command zmodload -i zsh/parameter insert-last-command-output() { - LBUFFER+="$(eval $history[$((HISTCMD-1))])" + LBUFFER+="$(eval $history[$((HISTCMD - 1))])" } zle -N insert-last-command-output bindkey "^Xl" insert-last-command-output - -# -- cgit v1.2.3