Closed mikea closed 8 years ago
I agree that would be better, but it might be difficult to get rid of duplicates and keep the order. Or it might be easy and I just don't know the solution. At any rate, I personally don't plan on making unique-ness and ordering both work together right now. Are you wanting both, or just not wanting the option hist_find_no_dups (that configures something else) to affect the ordering? We could make a different zaw-specific option to just force history uniqueness, rather than hijacking the built-in option.
:+1: to order being important than no dupes.
zaw now uses a zstyle to decide whether or not to ignore duplicates instead of the built-in zsh setting, so you can choose which you want zaw to do irrespective of what other parts of zsh do.
but it might be difficult to get rid of duplicates and keep the order
@willghatch Algorithmically it can be done as follows: http://unix.stackexchange.com/a/84838/44493
Fixed in #81.
After https://github.com/zsh-users/zaw/commit/5e466526d8abc1865691d238b660b2a8591b61fc hist_find_no_dups randomizes entries order, which is terribly inconvenient. The order of entries should always have more recent items on top.