mirror of
https://github.com/zsh-users/zsh-autosuggestions.git
synced 2026-11-29 20:03:11 +01:00
fix:Add autosuggest to highlighters list only once
This commit is contained in:
1 parent
bd11c34e84
commit
6dbb419a7a
1 file changed
+3
-1
+3
-1
@@ -100,7 +100,9 @@ autosuggest-resume() {
|
|||||||
|
|
||||||
autosuggest-start() {
|
autosuggest-start() {
|
||||||
if [[ -z $ZLE_DISABLE_AUTOSUGGEST && -n $functions[_zsh_highlight] ]]; then
|
if [[ -z $ZLE_DISABLE_AUTOSUGGEST && -n $functions[_zsh_highlight] ]]; then
|
||||||
ZSH_HIGHLIGHT_HIGHLIGHTERS+=(autosuggest)
|
if [[ ${ZSH_HIGHLIGHT_HIGHLIGHTERS[(i)autosuggest]} -gt ${#ZSH_HIGHLIGHT_HIGHLIGHTERS} ]];then
|
||||||
|
ZSH_HIGHLIGHT_HIGHLIGHTERS+=(autosuggest)
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
autosuggest-resume
|
autosuggest-resume
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in new issue
Block a user