mirror of
https://github.com/zsh-users/zsh-autosuggestions.git
synced 2024-11-18 09:51:06 +01:00
Disable autosuggest if buffer is too large
This commit is contained in:
parent
62cdba4e0f
commit
9572ccbea2
2 changed files with 2 additions and 2 deletions
|
@ -24,7 +24,7 @@ _zsh_autosuggest_modify() {
|
||||||
|
|
||||||
# Get a new suggestion if the buffer is not empty after modification
|
# Get a new suggestion if the buffer is not empty after modification
|
||||||
local suggestion
|
local suggestion
|
||||||
if [ $#BUFFER -gt 0 ]; then
|
if [ $#BUFFER -gt 0 -a $#BUFFER -lt 20 ]; then
|
||||||
suggestion="$(_zsh_autosuggest_suggestion "$BUFFER")"
|
suggestion="$(_zsh_autosuggest_suggestion "$BUFFER")"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
|
@ -242,7 +242,7 @@ _zsh_autosuggest_modify() {
|
||||||
|
|
||||||
# Get a new suggestion if the buffer is not empty after modification
|
# Get a new suggestion if the buffer is not empty after modification
|
||||||
local suggestion
|
local suggestion
|
||||||
if [ $#BUFFER -gt 0 ]; then
|
if [ $#BUFFER -gt 0 -a $#BUFFER -lt 20 ]; then
|
||||||
suggestion="$(_zsh_autosuggest_suggestion "$BUFFER")"
|
suggestion="$(_zsh_autosuggest_suggestion "$BUFFER")"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue