Fzf: exact ignores space

Created on 20 Jun 2019  路  3Comments  路  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

    • [ ] zsh

    • [ ] fish

I tried to find exactly "map m" in my list , so I wrote 'map m in the search.
It completely ignored the m and looked for the exact string map.
I am not sure if it is expected. I am sure you might want to search something with space in the middle.

question

Most helpful comment

  1. Ideally, when you type in mapm, the ranking algorithm of fuzzy matcher will put map m at the top of the list. This may not be true if there are exact mapm matches.
  2. Yes, 'map\ m should work here.
  3. --actually-the-exact-set-of-letters-I-typed-in-this-particular-order is --no-extended --exact (or +x -e)

All 3 comments

I understand your issue. At the same time I really like the current behaviour, because I can look for two or more exact strings.

I usually do something like

docker images | fzf -e
> gcr alp

to get every line with those two exact strings in them.

I don't know how we could go about supporting both behaviours, or if we should.
-e, --exact does what I expect it to do, but not what you expect it to do. What you need is something like --actually-the-exact-set-of-letters-I-typed-in-this-particular-order.

Anyway, I just wanted to voice the the other side.

Current behaviour is nice, but an option like --actually-the-exact-set-of-letters-I-typed-in-this-particular-order would still be good too for some use cases. (like grep -F)

Anyway, @eyalk5 the solution for now is 'map\ m or use --exact option and then omit the ' in the query.

  1. Ideally, when you type in mapm, the ranking algorithm of fuzzy matcher will put map m at the top of the list. This may not be true if there are exact mapm matches.
  2. Yes, 'map\ m should work here.
  3. --actually-the-exact-set-of-letters-I-typed-in-this-particular-order is --no-extended --exact (or +x -e)
Was this page helpful?
0 / 5 - 0 ratings

Related issues

nordlow picture nordlow  路  3Comments

olethanh picture olethanh  路  3Comments

sandric picture sandric  路  3Comments

chrisamow picture chrisamow  路  3Comments

lbeier picture lbeier  路  3Comments