Fzf: function key binds no longer work?

Created on 22 Nov 2016  路  4Comments  路  Source: junegunn/fzf

  • Category

    • [x] fzf binary

    • [ ] fzf-tmux script

    • [ ] Key bindings

    • [ ] Completion

    • [ ] Vim

    • [x] Neovim

    • [ ] Etc.

  • OS

    • [ ] Linux

    • [x] Mac OS X

    • [ ] Windows

    • [ ] Windows Subsystem for Linux

    • [ ] Etc.

  • Shell

    • [ ] bash

    • [x] zsh

    • [ ] fish

Previously I had <f2> bound to :Buffers in fzf.vim
Since <f2> triggers ^[OQ^C, it technically hits <esc> and can close the FZF :term on its own (<f2> to open, <f2> or <esc> to close)

Now in 0.15.8 the function keys are not read the same, and even --bind=f2:abort does not work in an fzf#run() options.
How can I bind <f2> (and f3,f4,etc) to close fzf.vim :terms?

neovim

Most helpful comment

Looks like there's ongoing work on fixing the issue: https://github.com/neovim/neovim/pull/5014

Until it's fixed in neovim, a workaround would be to remap function keys to another key chords that fzf understands.

autocmd FileType fzf tnoremap <buffer> <f1> <c-c>

All 4 comments

Since 0.15.8, fzf relies on ncurses to interpret escape sequences for function keys. And it works as expected on terminal: fzf --bind f2:abort. So the problem you have seems to be an issue of Neovim terminal. Maybe this? https://github.com/neovim/neovim/issues/4343

Yes, it's a neovim terminal only issue -- that might be related

Looks like there's ongoing work on fixing the issue: https://github.com/neovim/neovim/pull/5014

Until it's fixed in neovim, a workaround would be to remap function keys to another key chords that fzf understands.

autocmd FileType fzf tnoremap <buffer> <f1> <c-c>

that works for me, thanks for solution!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

natemara picture natemara  路  3Comments

asilvadesigns picture asilvadesigns  路  3Comments

firedev picture firedev  路  3Comments

olethanh picture olethanh  路  3Comments

chrisamow picture chrisamow  路  3Comments