-
Notifications
You must be signed in to change notification settings - Fork 299
Quick Open Case Sensitivity #825
Comments
Ah it's actually a bit confusing (and good for us to clarify). Thanks for calling this out. We actually only every call The logic that is impacting this is our filtering of results here: And there are two phases of filtering there (after we get the results from the finder process, which defaults to
The So there's really three phases: (2) and (3) are always run after the finder process returns results, so that we can rank + do the highlighting in the menu. I was looking through this and it seems like the pre-filter pass (2) is case-sensitive, whereas the (3) I'm thinking we could do the following:
If we had that setting, it would at least help clarify the behavior. The only downside is that, if a custom Thanks for logging the issue @CrossR and the ideas @badosu ! I'll give it a shot tomorrow morning - let me know if you have any feedback on the proposal. |
@bryphe Defaulting case sensitivity to 'smart' would be a good idea I think (it would be good enough for me, and probably for most people). Also, if someone is configuring To be frank I am not sure why we have this complicated setup, shouldn't ripgrep be fast enough to be called each time? At least that's how most of the Vim world uses a fuzzy-finder, but I should test both configurations to be sure it's better than what we have (probably not). |
As far as I can tell, the quick open window is Case sensitive?
If that is the case, I suggest instead that Oni copy Vims config options for
ignorecase
andsmartcase
.Ignore case is fairly self explanatory, we just always ignore the case, IE
a
returnsA
ora
.Smart case is slightly different, you ignore case when a lower case string is given, but if you include upper case letters then it swaps to case-sensitive search.
apple
returnsApple
,apple
,APPLE
or any other combo, but searching foraPPle
will only returnaPPle
.I'm quite used to using just lower case search terms as I have this set in Vim, so having the quick open window work similarly would be nice.
After having a quick look, it looks like we explicitly pass over a "--case-sensitive" flag to ripgrep, so it would look like I can add a config option or two to pass over "--ignore-case" or "--smart-case" instead?
Assuming that sounds okay, what config options would we want?
The text was updated successfully, but these errors were encountered: