Part of #358.
Goal
Persist generated-buffer rail style so stacked buffers remain stacked across refresh and :edit reloads.
Scope
- Store a generated buffer rail style, for example
b:diffs_rail_style = 'dual'|'single', alongside existing rail width vars.
- Add a helper to read the buffer rail style with
dual as the compatibility default.
- Extend generated buffer creation to accept a rail style and pass it to rail annotation.
- Extend generated buffer replacement/reload to preserve the existing buffer rail style when no explicit override is supplied.
- Ensure generated hunk action metadata is still parsed from raw diff lines, not rail-prefixed display lines.
Non-goals
- Do not introduce a public config option.
- Do not store rail style in source metadata unless the implementation needs it for reliable reloads.
- Do not alter default unified buffers.
Acceptance criteria
- Generated buffers carry rail width, separator width, and style metadata.
- Replacing generated diff lines preserves single rail style when the buffer was created as single rail.
commands.read_buffer() / :edit reload does not revert stacked buffers back to dual rails.
- Raw hunk metadata remains rail-free and usable for hunk actions.
Verification
- Add command/reload specs proving single rail style survives replacement/reload.
- Add a regression assertion that stored hunk line text remains raw unified diff text.
Part of #358.
Goal
Persist generated-buffer rail style so stacked buffers remain stacked across refresh and
:editreloads.Scope
b:diffs_rail_style = 'dual'|'single', alongside existing rail width vars.dualas the compatibility default.Non-goals
Acceptance criteria
commands.read_buffer()/:editreload does not revert stacked buffers back to dual rails.Verification