mgalgs / fuzzy_bash_completion

Fuzzy tab completion for bash.
94 stars 9 forks source link

Is there a how-to tutorial on this? #3

Closed jsliang closed 11 years ago

jsliang commented 11 years ago

Hi @mgalgs, I'm looking for a fuzzy bash completion plugin and this seems to be a perfect solution to me. However, after executing fuzzy_replace_filedir_xspec, I don't know how to use it -- for example, which key shall I press to trigger the fuzzy completion? What text will I see see when using it in bash? Do you have a tutorial on this? Thank you!

mgalgs commented 11 years ago

I don't have a tutorial (I'll try to add something somewhere) but it should work roughly the same way as normal bash completion, but should be "fuzzy". So you just need to hit TAB to get it to work. If it still doesn't work then your bash_completion package might not be using the filedir_xspec that that special function looks for. As a simple test, do:

fuzzy_setup_for_command cd
mkdir pizza
mkdir jazz

then see if cd zz <TAB> <TAB> gives you those completions.

jsliang commented 11 years ago

Thank you! It works like a charm. :)