sourcebot/.github/workflows
Brendan Kellam 7f952ce163
Search suggestions (#85)
The motivation for building search suggestions is two-fold: (1) to make the zoekt query language more approachable by presenting all available options to the user, and (2) make it easier for power-users to craft complex queries.

The meat-n-potatoes of this change are concentrated in searchBar.tsx and searchSuggestionBox.tsx. The suggestions box works by maintaining a state-machine of "modes". By default, the box is in the refine mode, where suggestions for different prefixes (e.g., repo:, lang:, etc.) are suggested to the user. When one of these prefixes is matched, the state-machine transitions to the corresponding mode (e.g., repository, language, etc.) and surfaces suggestions for that mode (if any).

The query is split up into parts by spaces " " (e.g., 'test repo:hello' -> ['test', 'repo:hello']). See splitQuery. The part that has the cursor over it is considered the active part. We evaluate which mode the state machine is in based on the active part. When a suggestion is clicked, we only modify the active part of the query.

Three modes are currently missing suggestion data: file (file names), revision (branch / tag names), and symbol (symbol names). In future PRs, we will need to introduce endpoints into the backend to allow the frontend to fetch this data and surface it as suggestions..
2024-11-22 18:50:13 -08:00
..
fly-deploy.yml update demo site fly.toml to use image from ghcr instead of building one. Also make the deployment pipeline dependent on pushes to ghcr. 2024-10-17 13:41:58 -04:00
ghcr-publish.yml Added SOURCEBOT_VERSION build arg + versioned telemetry (#41) 2024-10-17 14:50:07 -04:00
pr-gate.yml Add simple PR gate that builds docker container for one platform 2024-09-19 17:21:24 -07:00
test-backend.yml Add unit testing library to @sourcebot/backend (#65) 2024-11-12 18:37:35 -08:00
test-web.yml Search suggestions (#85) 2024-11-22 18:50:13 -08:00