Open knutwannheden opened 2 years ago
I'm don't think fzf's algorithm is a great fit for zoxide. The use case is entirely different:
fzf is an interactive program:
zoxide, on the other hand:
Thanks for your feedback. I don't quite agree with your concerns, so let me elaborate.
The user will know (or quickly learn) what characters he needs to type to get a unique match, so I don't think the number of matches would increase. And the idea was that this matching algorithm would be an alternative non-default strategy, so users could continue using zoxide like they are used to.
If I expand my previous example to include the directories framework-a
, framework-b
, client-a
, and client-b
(this is fictitious but large organizations with many Git repos often have such strict naming conventions), I would be able to type fa
(or fwa
or similar) which I think would be really nice as an alternative.
You could allow non-consecutive characters in queries when using zi
, since it will pull up fzf
to refine your search.
For anyone looking to do this right now, I've managed to hack the shell functions to use fzf
on top of zoxide query
. Put one of the following after the line that adds zoxide to your shell:
Maybe I am missing something, but if I in my history have a directory like
framework
I would like to be able to typez fwk
to change to that directory. Sincefzf
generally allows for this kind of thing, I was expecting to be able to do that with zoxide, but I couldn't find any way. If I am not missing anything, then please consider this as an enhancement request for a corresponding option.