Merge pull request #159 from dxrcy/master

Fix user input after search
This commit is contained in:
Guido van Steen 2024-06-05 07:04:53 +02:00 committed by GitHub
commit 87ce96b186
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -406,7 +406,7 @@ _history-substring-search-end() {
# For debugging purposes: # For debugging purposes:
# zle -R "mn: "$_history_substring_search_match_index" m#: "${#_history_substring_search_matches} # zle -R "mn: "$_history_substring_search_match_index" m#: "${#_history_substring_search_matches}
# read -k -t 200 && zle -U $REPLY # read -k -t 200 && zle -U -- "$REPLY"
# #
# When this function returns, z-sy-h runs its line-pre-redraw hook. It has no # When this function returns, z-sy-h runs its line-pre-redraw hook. It has no
@ -421,7 +421,7 @@ _history-substring-search-end() {
# before removing search highlight and exiting. This ensures no highlights # before removing search highlight and exiting. This ensures no highlights
# are left lingering after search is finished. # are left lingering after search is finished.
# #
read -k -t ${HISTORY_SUBSTRING_SEARCH_HIGHLIGHT_TIMEOUT:-1} && zle -U $REPLY read -k -t ${HISTORY_SUBSTRING_SEARCH_HIGHLIGHT_TIMEOUT:-1} && zle -U -- "$REPLY"
region_highlight=( "${(@)region_highlight:#*${highlight_memo}*}" ) region_highlight=( "${(@)region_highlight:#*${highlight_memo}*}" )
fi fi