Skip to content

web: remove regex anchors if globbing is active

Administrator requested to merge sh/globbing-web into master

Created by: stefanhengl

This PR builds on top of https://github.com/sourcegraph/sourcegraph/pull/12093 and #12365

For additional context see RFC198

We want to support globbing for fields repo, file, and repohasfile. #12093 contains the changes in the backend. However, the frontend still adds regex anchors ^ and $ when navigating the UI. This essentially breaks search when globbing is active.

image

This PR adds globbing awareness to

  • completion
  • suggestion
  • filters

To test locally, set the following settings:

{
    "search.globbing": true,
    "search.migrateParser": true
}

Merge request reports

Loading