aboutsummaryrefslogtreecommitdiff
path: root/tests/test-modeline-config-vc-cache-key.el
Commit message (Collapse)AuthorAgeFilesLines
* fix(modeline): drop per-render truename, guard vc fetch against signalsCraig Jennings2026-06-141-40/+20
| | | | The VC modeline cache rebuilt its key every render, and the key included file-truename, so a stat ran on every redisplay rather than once per refresh as the comment claimed. Now it keys on (file show-remote). A moved symlink target is caught at the next TTL refresh, when vc-backend resolves the link fresh. And cj/modeline-vc-fetch is wrapped in condition-case returning nil, so a git signal on a slow or unmounted filesystem degrades to no-VC-info instead of breaking all redisplay.
* fix(modeline): key VC cache on resolved truename for symlink movesCraig Jennings2026-05-241-0/+56
The VC modeline cache keyed on (list file cj/modeline-vc-show-remote). If file was a symlink whose target moved to a different VC tree (shared drives, CI workspaces), the key was unchanged and the cache kept serving the old branch/state. Added the resolved file-truename to the key, so a symlink re-pointed at a new target produces a different key and the cache refreshes. The extra file-truename is one stat per modeline refresh, cheap next to the VC calls the cache exists to avoid. Tests cover truename inclusion, key stability for an unchanged file, and a symlink whose target moves.