Summary:
When you have a lot of projects open, finding a thread from a specific
project in the archive ("Search all threads") view is slower than it
should be — the filter only matches the thread title, so you have to
remember or scan titles to find what belongs to which project. Folder
names are a quicker mental handle than thread titles, especially across
many projects.
This PR makes the archive filter also try matching the basename of each
of the thread's worktree paths. Title matches still take precedence and
get the highlight positions; project-name matches just include the row.
Same `fuzzy_match_positions` contiguous substring matcher already used
for titles, so the matching feel is consistent.
Example: typing `my-laravel-project` now surfaces every thread that
lives
under a project named `my-laravel-project`, regardless of title.
Self-Review Checklist:
- [x] I've reviewed my own diff for quality, security, and reliability
- [x] Unsafe blocks (if any) have justifying comments — N/A
- [x] The content is consistent with the [UI/UX
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)
- [x] Tests cover the new/changed behavior — small extension to an
existing filter branch; manually verified.
- [x] Performance impact has been considered and is acceptable — per-row
path-basename check only runs when the title didn't match.
Release Notes:
- Improved the archive "Search all threads" view so you can filter by
project name, not just by thread title — handy when many projects are
open.
---------
Co-authored-by: Danilo Leal <daniloleal09@gmail.com>1 file changedLine totals unavailable