This repository has been archived by the owner on Apr 1, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 298
Highlight the wrong parts while searching in the command palette? #304
Labels
Comments
I'd like to add to this as well, if you open and search for "init.vim" it
doesn't pop up, despite being an exact result. Um jot sure this this is a
search algorithm bug or just a result of fuzzy searching, but it's an issue
…On Mar 19, 2017 10:44 PM, "Guilherme Leobas" ***@***.***> wrote:
[image: image]
<https://cloud.githubusercontent.com/assets/2712115/24087281/d43f4df8-0cfb-11e7-9c48-980a1c059065.png>
*"Open"* keyword should be highlighted.
—
You are receiving this because you are subscribed to this thread.
Reply to this email directly, view it on GitHub
<#304>, or mute the thread
<https://github.com/notifications/unsubscribe-auth/AICBCcUQ2EjGWgSH-dbvRbk_gvd5IwnMks5rnef3gaJpZM4Mh-yV>
.
|
It's an issue with the search algorithm. It's looking at the entire path and removing a character from the search string as it finds a match. You can see it highlighted I don't know if we need to search the filename first or allow for characters in the search string to happen multiple times. I've been giving this some thought but I don't have a good solution yet. |
I don't know how taxing it is, but sequence matcher or a rough search on
the actual filename and then on the full path but with lower precedence
would be a good start.
…On Mar 19, 2017 11:36 PM, "keforbes" ***@***.***> wrote:
It's an issue with the search algorithm. It's looking at the entire path
and removing a character from the search string as it finds a match. You
can see it highlighted o, p, e in the path and by the time it got to the
filename it only had n left in the search string.
I don't know if we need to search the filename first or allow for
characters in the search string to happen multiple times. I've been giving
this some thought but I don't have a good solution yet.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#304 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AICBCQHShEKT2nmNnlQJNASo2htQAcnwks5rnfQhgaJpZM4Mh-yV>
.
|
Yep, the algorithm is a bit busted. Most of this happens in |
Might be worth replacing the algorithm we're using with a library like fuzzy. |
This library also looked interesting: http://fusejs.io/ |
Created #306 using fuse.js. |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
"Open" keyword should be highlighted.
The text was updated successfully, but these errors were encountered: