Files
zed/crates/git
Kunall Banerjee ec86047d67 git: Reflect external stash renames (#55294)
Zed reads `%s` (commit subject) from `git stash list`, but external
rename tools (lazygit, or `git stash store -m` directly) update only the
reflog message and never rewrite the underlying commit. The stash picker
therefore keeps showing the original message forever after an external
rename, even across restarts — no amount of cache invalidation or
fs-watching can fix that, because the data we ask git for genuinely
never changes.

Switch to `%gs` (reflog subject), which is what `git stash list`
displays by default and what `git stash store -m` actually updates. Also
correct an adjacent error message that claimed `git status failed` when
the failing command was `git stash list`.

Self-Review Checklist:

- [x] I've reviewed my own diff for quality, security, and reliability
- [ ] Unsafe blocks (if any) have justifying comments
- [ ] The content is consistent with the [UI/UX
checklist](https://github.com/zed-industries/zed/blob/main/CONTRIBUTING.md#uiux-checklist)
- [ ] Tests cover the new/changed behavior
- [ ] Performance impact has been considered and is acceptable

Closes #55234.

Release Notes:

- Fixed external stash renames not being reflected in the stash picker

Co-authored-by: Finn Evers <finn@zed.dev>
2026-10-27 01:48:19 +00:00
..