helix-editor / helix

A post-modern modal text editor.
https://helix-editor.com
Mozilla Public License 2.0
32.79k stars 2.42k forks source link

Match file names before file paths in file picker #6581

Closed keirlawson closed 1 year ago

keirlawson commented 1 year ago

when searching for my Main.scala file in a scala project the picker instead matches every single file in /src/main when I search for main. VS Code by contrast will match Main.scala first in this case, and I believe Helix should follow this behavior.

pascalkuthe commented 1 year ago

Can you lost a screenshot. The Main.scala file should have a higher fuzzy score than src/main/too.scala and should be shown first. In general there is no special logic for files in the licker. All pickers use a generic fuzzy matching algorithm so there will be no slecical handeling for the filename

keirlawson commented 1 year ago

I suspect the issue is I search all in lower case, so it matches the path first as the file name is capitalised. Has there been any discussion of having the file picker only search file names, rather than file names + paths? This could be something I could look at contributing if its desirable.