From 8c0998d23266017cf1ab488f8c0295ec45aee14b Mon Sep 17 00:00:00 2001 From: Arnaud Venturi Date: Mon, 4 Dec 2017 16:59:41 +0100 Subject: [PATCH] First version working calling the widgets --- src/bind.zsh | 1 - src/widgets.zsh | 4 ++-- zsh-autosuggestions.zsh | 5 ++--- 3 files changed, 4 insertions(+), 6 deletions(-) diff --git a/src/bind.zsh b/src/bind.zsh index 3d84b43..be0d164 100644 --- a/src/bind.zsh +++ b/src/bind.zsh @@ -109,7 +109,6 @@ _zsh_autosuggest_invoke_original_widget() { [ $# -gt 0 ] || return local original_widget_name="$1" - print $original_widget_name shift diff --git a/src/widgets.zsh b/src/widgets.zsh index 851804a..e49780d 100644 --- a/src/widgets.zsh +++ b/src/widgets.zsh @@ -172,8 +172,8 @@ _zsh_autosuggest_suggest() { _zsh_autosuggest_accept() { # Accepting the whole line is basically a specific case of # accepting partially with "end-of-line" widget -# _zsh_autosuggest_partial_accept ".end-of-line" - _zsh_autosuggest_partial_accept "end-of-line" + # TODO : find a non-hardcoded way to call this widget + _zsh_autosuggest_partial_accept "autosuggest-orig-1-end-of-line" } # Accept the entire suggestion and execute it diff --git a/zsh-autosuggestions.zsh b/zsh-autosuggestions.zsh index 1e9bdda..817f144 100644 --- a/zsh-autosuggestions.zsh +++ b/zsh-autosuggestions.zsh @@ -230,7 +230,6 @@ _zsh_autosuggest_invoke_original_widget() { [ $# -gt 0 ] || return local original_widget_name="$1" - print $original_widget_name shift @@ -438,8 +437,8 @@ _zsh_autosuggest_suggest() { _zsh_autosuggest_accept() { # Accepting the whole line is basically a specific case of # accepting partially with "end-of-line" widget -# _zsh_autosuggest_partial_accept ".end-of-line" - _zsh_autosuggest_partial_accept "end-of-line" + # TODO : find a non-hardcoded way to call this widget + _zsh_autosuggest_partial_accept "autosuggest-orig-1-end-of-line" } # Accept the entire suggestion and execute it