Initialize option to empty string instead of unsetting.

This commit is contained in:
Geza Lore 2016-05-22 09:30:52 +01:00
parent 8224802bda
commit b546105d7e
2 changed files with 7 additions and 7 deletions

View file

@ -104,16 +104,16 @@ default values only after having loaded this script into your ZSH session.
* HISTORY_SUBSTRING_SEARCH_ENSURE_UNIQUE is a global variable that defines * HISTORY_SUBSTRING_SEARCH_ENSURE_UNIQUE is a global variable that defines
whether all search results returned are _unique_. If set to a non-empty whether all search results returned are _unique_. If set to a non-empty
value, then only unique search results are presented. It is unset by value, then only unique search results are presented. This behaviour is off
default. An alternative way to ensure that search results are unique is by default. An alternative way to ensure that search results are unique is
to use `setopt HIST_IGNORE_ALL_DUPS`. If both this configuration variable to use `setopt HIST_IGNORE_ALL_DUPS`. If this configuration variable is off
and `setopt HIST_IGNORE_ALL_DUPS` are unset, then `setopt HIST_FIND_NO_DUPS` and `setopt HIST_IGNORE_ALL_DUPS` is unset, then `setopt HIST_FIND_NO_DUPS`
is still respected, and makes this plugin skip duplicate _adjacent_ search is still respected and it makes this plugin skip duplicate _adjacent_ search
results as you cycle through them, but this does not guarantee that search results as you cycle through them, but this does not guarantee that search
results are unique: if your search results were "Dog", "Dog", "HotDog", results are unique: if your search results were "Dog", "Dog", "HotDog",
"Dog", then cycling them gives "Dog", "HotDog", "Dog". Notice that the "Dog" "Dog", then cycling them gives "Dog", "HotDog", "Dog". Notice that the "Dog"
search result appeared twice as you cycled through them. If you wish to search result appeared twice as you cycled through them. If you wish to
receive globally unique search results only once, then set this receive globally unique search results only once, then use this
configuration variable, or use `setopt HIST_IGNORE_ALL_DUPS`. configuration variable, or use `setopt HIST_IGNORE_ALL_DUPS`.
------------------------------------------------------------------------------ ------------------------------------------------------------------------------

View file

@ -45,7 +45,7 @@
HISTORY_SUBSTRING_SEARCH_HIGHLIGHT_FOUND='bg=magenta,fg=white,bold' HISTORY_SUBSTRING_SEARCH_HIGHLIGHT_FOUND='bg=magenta,fg=white,bold'
HISTORY_SUBSTRING_SEARCH_HIGHLIGHT_NOT_FOUND='bg=red,fg=white,bold' HISTORY_SUBSTRING_SEARCH_HIGHLIGHT_NOT_FOUND='bg=red,fg=white,bold'
HISTORY_SUBSTRING_SEARCH_GLOBBING_FLAGS='i' HISTORY_SUBSTRING_SEARCH_GLOBBING_FLAGS='i'
unset HISTORY_SUBSTRING_SEARCH_ENSURE_UNIQUE HISTORY_SUBSTRING_SEARCH_ENSURE_UNIQUE=''
#----------------------------------------------------------------------------- #-----------------------------------------------------------------------------
# the main ZLE widgets # the main ZLE widgets