Commit 314e9ae
committed
Git browser: M1 foundation
- Add `file_system/git/` module: `discover_repo` via `gix::discover` (follows gitlinks), `repo_info` (branch, ahead/behind, dirty), `list_status` (porcelain v2 shell-out), notify-rs watcher, and friendly errors
- Wire IPC commands `get_git_repo_info`, `subscribe_git_state`, `unsubscribe_git_state`, `get_git_status_for_paths` with `blocking_with_timeout` and `git-state-changed` event
- Schema additions inert until M2/M3: `FileEntry.redirectToPath`, four `git:*` icon IDs, `--color-git-portal` CSS token
- Frontend `file-explorer/git/` module: `RepoChip.svelte` (six visual states) + `git-store.svelte.ts` (refcounted per-repo subscriptions) + `status-column.ts` helpers
- `FilePane.svelte` drives the chip via `lookupRepoInfo` + `subscribeToRepo`; refresh on `git-state-changed`, no polling
- `FullList.svelte` adds an optional Git column right after Name, gated by `fileExplorer.git.showStatusColumn` and only rendered inside a worktree; refreshes from `fetchStatusMap` on `git-state-changed`
- Settings: `fileExplorer.git.showRepoChip`, `showStatusColumn`, `showVirtualGitPortal`
- Bench: discover + repo_info p95 ~66 ms, list_status p95 ~75 ms on a 50k-file synth fixture (under the 100 ms hard cap)
- Decision documented: shell out to `git status --porcelain=v2 -z` because gix's status iter missed staged adds in our fixtures
- Docs: new CLAUDE.md in `file_system/git/` and `file-explorer/git/`; updates to `file-explorer/CLAUDE.md`, `views/CLAUDE.md`, `volume/CLAUDE.md`, `docs/architecture.md`; CHANGELOG entry under [Unreleased]1 parent 10b220a commit 314e9ae
35 files changed
Lines changed: 4372 additions & 108 deletions
File tree
- apps/desktop
- src-tauri
- src
- commands/file_system
- file_system
- git
- listing
- volume
- src
- lib
- file-explorer
- git
- pane
- views
- settings
- docs
- specs
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
8 | 20 | | |
9 | 21 | | |
10 | 22 | | |
| |||
0 commit comments