Closed Bug 1751401 Opened 3 years ago Closed 3 years ago

Add the possibility to have few lines of context in a search results

Categories

(Webtools :: Searchfox, enhancement)

enhancement

Tracking

(Not tracked)

RESOLVED DUPLICATE of bug 1414954

People

(Reporter: calixte, Unassigned)

Details

I use a lot the options -A and -B with ripgrep to get few lines of context around the queried string.
From my point of view it's super useful to quickly guess what's relevant for me.

Nice !!
How could I have found that myself without filing a bug ?
It seems that's it works only for textual occurrences:
https://searchfox.org/mozilla-central/search?q=context%3A5+defineLazyModuleGetters&path=

It's unfortunately a secret feature at this time because, as you discovered, it is only for full-text search. More details/rationale at https://github.com/mozsearch/mozsearch/pull/417

We're much closer to being able to provide this across result types. For the time being you can force a full-text search by using a path filter or enabling regexp. (Semantic results suppress full-text search results on the same lines, so in order to get full-text results only and therefore context, we need to not do semantic searches.)

Status: NEW → RESOLVED
Closed: 3 years ago
Resolution: --- → DUPLICATE
You need to log in before you can comment on or make changes to this bug.