fix(cli): indent stack members instead of a reserved gutter lane - #70
Merged
Conversation
lettertwo
force-pushed
the
lane-graph-indentation
branch
from
August 28, 2026 03:13
8882f18 to
e331f60
Compare
lettertwo
force-pushed
the
lane-graph-indentation
branch
from
August 29, 2026 23:35
e331f60 to
99e91e9
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This PR is not about gh-stack. It fixes a pre-existing ADR-026 bug that a Graphite user with one
tracked stack hits today.
The lane graph let a trunk hand its own lane to its primary child. With one stack and no forks,
every row rendered flush left, indistinguishable from an unrelated worktree, and the trunk carried
no marker. Indentation carried no information in the single-stack case, which is the common case.
Column 0 is now reserved for bases. A trunk or an ungrouped worktree renders flush left, and every
stack member sits in column 1 or further right, so indentation alone signals membership. A base
never hands its lane to a child, so all its children close on its row (
◉─┴─╯ main) and graph widthis the number of concurrent stacks on that trunk, independent of any one stack's depth.
Ordering changes from most-active-subtree to tallest subtree first, with activity demoted to a
tiebreaker and branch name as the final tiebreak.
TreeNodegainssubtree_size.docs/adr/026-graphite-lane-graph.mdis rewritten to match. An earlier revision of it reserved lane0 as a dedicated membership column, which is kept there under "Superseded".
The change is textually dependent on the gh-stack work: it touches
stack_numberin six places,TreeNode::stack_numberexists only because ofStack::number, and it edits lane examples indocs/recipes/stacked-diffs.md.Testing: 651 tests, clippy clean.
Stack created with GitHub Stacks CLI • Give Feedback 💬