mirror of
https://github.com/dcarrillo/prezto.git
synced 2024-12-22 12:48:01 +00:00
history-substring-search: add fuzzy and unique
This commit is contained in:
parent
1b0cc0a219
commit
bd180eec72
@ -65,6 +65,24 @@ _`${ZDOTDIR:-$HOME}/.zpreztorc`_:
|
|||||||
zstyle ':prezto:module:history-substring-search' globbing-flags ''
|
zstyle ':prezto:module:history-substring-search' globbing-flags ''
|
||||||
```
|
```
|
||||||
|
|
||||||
|
### Fuzzy search
|
||||||
|
|
||||||
|
To enable fuzzy search add the following line to
|
||||||
|
`${ZDOTDIR:-$HOME}/.zpreztorc`_:
|
||||||
|
|
||||||
|
```sh
|
||||||
|
zstyle ':prezto:module:history-substring-search' fuzzy 'yes'
|
||||||
|
```
|
||||||
|
|
||||||
|
### Unique results
|
||||||
|
|
||||||
|
To retrieve only unique results (remove duplicates) add the following line to
|
||||||
|
`${ZDOTDIR:-$HOME}/.zpreztorc`_:
|
||||||
|
|
||||||
|
```sh
|
||||||
|
zstyle ':prezto:module:history-substring-search' ensure-unique 'yes'
|
||||||
|
```
|
||||||
|
|
||||||
## Authors
|
## Authors
|
||||||
|
|
||||||
_The authors of this module should be contacted via the [issue tracker][5]._
|
_The authors of this module should be contacted via the [issue tracker][5]._
|
||||||
|
@ -38,6 +38,14 @@ if ! zstyle -t ':prezto:module:history-substring-search' color; then
|
|||||||
unset HISTORY_SUBSTRING_SEARCH_HIGHLIGHT_{FOUND,NOT_FOUND}
|
unset HISTORY_SUBSTRING_SEARCH_HIGHLIGHT_{FOUND,NOT_FOUND}
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if zstyle -t ':prezto:module:history-substring-search' fuzzy; then
|
||||||
|
HISTORY_SUBSTRING_SEARCH_FUZZY=1
|
||||||
|
fi
|
||||||
|
|
||||||
|
if zstyle -t ':prezto:module:history-substring-search' ensure-unique; then
|
||||||
|
HISTORY_SUBSTRING_SEARCH_ENSURE_UNIQUE=1
|
||||||
|
fi
|
||||||
|
|
||||||
#
|
#
|
||||||
# Key Bindings
|
# Key Bindings
|
||||||
#
|
#
|
||||||
|
@ -109,6 +109,12 @@ zstyle ':prezto:module:editor' key-bindings 'emacs'
|
|||||||
# Set the search globbing flags.
|
# Set the search globbing flags.
|
||||||
# zstyle ':prezto:module:history-substring-search' globbing-flags ''
|
# zstyle ':prezto:module:history-substring-search' globbing-flags ''
|
||||||
|
|
||||||
|
# Enable fuzzy search
|
||||||
|
# zstyle ':prezto:module:history-substring-search' fuzzy 'yes'
|
||||||
|
|
||||||
|
# Retrieve only unique results (removes duplicates)
|
||||||
|
# zstyle ':prezto:module:history-substring-search' ensure-unique 'yes'
|
||||||
|
|
||||||
#
|
#
|
||||||
# macOS
|
# macOS
|
||||||
#
|
#
|
||||||
|
Loading…
Reference in New Issue
Block a user