git: Split up compute snapshot to improve repository responsiveness (#51882)

## Context

This should allow the UI to update faster with stateful git operations
like branch changes, commits, etc. This will also allow Zed to
recognized when a new project belongs to a branch sooner than before.


## Self-Review Checklist

<!-- Check before requesting review: -->
- [x] I've reviewed my own diff for quality, security, and reliability
- [x] Unsafe blocks (if any) have justifying comments
- [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
- [x] Performance impact has been considered and is acceptable

Release Notes:

- git: Speed up UI responsiveness to branch/worktree changes
f9f1920452Anthony Eid committed on 3/23/2026, 12:57:38 PM· committed by GitHubparentadb3533
1 file changedLine totals unavailable