Add an option to remove duplicates from search

Some users may prefer to keep duplicates in their zsh history, but
drop them from search.  The awk manual[0] recommends this.

[0] https://www.gnu.org/software/gawk/manual/html_node/History-Sorting.html
This commit is contained in:
Javi Merino
2022-05-12 07:42:17 +01:00
parent 76c6588204
commit 44b785e81b
2 changed files with 17 additions and 1 deletions

View File

@@ -44,6 +44,7 @@ plugins=(… zsh-fzf-history-search)
| `ZSH_FZF_HISTORY_SEARCH_END_OF_LINE` | Put the cursor on at the end of the line after completion, `empty=false` (default: `''`) |
| `ZSH_FZF_HISTORY_SEARCH_EVENT_NUMBERS` | Include event numbers in search. Set to 0 to remove event numbers from the search. (default: `1`)|
| `ZSH_FZF_HISTORY_SEARCH_DATES_IN_SEARCH` | Include ISO8601 timestamps in search. Set to 0 to remove them from the search. (default: `1`) |
| `ZSH_FZF_HISTORY_SEARCH_REMOVE_DUPLICATES`| Remove duplicate entries from search. Only makes sense with `EVENT_NUMBERS` and `DATE_INSEARCH` 0 (false). (default: ``) |
## TODO