git_store: Coalesce refresh pathspecs (#56406)

Coalesce repo-relative paths before refreshing git status and diff
state. The worktree scanner can report both a directory and its
descendants in the same repository bucket, which makes git receive
redundant pathspecs.

This keeps refresh commands smaller for large repositories such as
Chromium, reducing git pathspec matching work and improving status
refresh performance during large worktree updates, as the initial repo
scan.

Partially fixes #43861

Release Notes:

- Reduced git CPU usage on large repos
bc823dbbbdHenrique Ferreiro committed on 6/1/2026, 12:28:20 PM· committed by GitHubparent0045814
1 file changedLine totals unavailable