Skip to content

[Feature Request] Combining --expect and --bind #3810

@ibhagwan

Description

@ibhagwan

Hi again @junegunn 👋

When scripting fzf, it is sometimes desirable to perform different actions upon completion depending on the key pressed, for example, in fzf-lua users use enter to open the file and ctrl-q to send the selection to quickfix list.

Now say that instead of sending the selection to quick fix we want to send all results to quickfix, we can do that with --bind=ctrl-q:select-all+accept but the output doesn’t print the pressed keybind, for that we need to add --expect:ctrl-q, however combining both we lose the --bind as expect takes over:

The below works but the select-all+accept action is ignored

fzf --expect=ctrl-q --bind=ctrl-q:select-all+accept

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingfeatureNew feature request

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions