lincheney / fzf-tab-completion

Tab completion using fzf
GNU General Public License v3.0
623 stars 40 forks source link

fzf not shown after prefix autocompletion (bash) #78

Closed treequin closed 1 year ago

treequin commented 1 year ago

I'm using bash and I wanted to use the common prefix autocompletion but I've ran into the problem that fzf is not shown after a prefix was completed.

So I replicated the example from the README with these results:

For example, if we have following files in a directory:

abcdef-1234
abcdef-5678
abc
other

With FZF_COMPLETION_AUTO_COMMON_PREFIX=true:

With FZF_COMPLETION_AUTO_COMMON_PREFIX_PART=true set as well:

In addition to the above, when FZF_COMPLETION_AUTO_COMMON_PREFIX_PART=true is set fzf is never shown, I tried it with every command I could think of and the tab completion only works if it can match a prefix or a full name, if it can't it shows "Loading matches ..." and nothing else.

I thought it could be caused by some option I'd changed in fzf, but I tried it on a fresh install with the same results. I also tried adding the variables to .bashrc instead of setting them from the terminal but it made no difference.

I'm fairly new to using the command line, so please let me know if I'm missing something obvious or if there's any troubleshooting I should do.

Thank you.

lincheney commented 1 year ago

Hi, I've pushed this commit https://github.com/lincheney/fzf-tab-completion/commit/aa71a4c202149dbe958d47b129ddc26d2592b793 which I think solves the issue Are you able to test it out?

treequin commented 1 year ago

Tested it and everything is working for me now. Thank you!