Skip to content

feat(git-history): mark a commit folded into the lane window with * - #1671

Merged
huichen merged 2 commits into
mainfrom
pr/huichen
Nov 22, 2026
Merged

huichen merged 2 commits into
mainfrom
pr/huichen

Conversation

@huichen

@huichen huichen commented Nov 22, 2026

Copy link
Copy Markdown
Collaborator

A commit whose lane was folded into the sixth column is now marked with * instead of o, so a windowed graph no longer reads as one line carrying several commits.

The six-lane cap draws lines past the sixth inside the last column, so a commit on one of them sat on a dot at a column that is not its own. A folded commit is now * in the host and TUI text graph, and the decoder carries folded through to the desktop and mobile panels, which draw it as a diamond instead of a disc. Nothing is dropped: every commit keeps its row, its place in the sixth column and its detail.

Commits

  • feat(git-history): mark a commit folded into the lane window with * — the glyph in host/src/git_history.rs and tui/src/workbench/git_panel.rs; tui/src/workbench/screen.rs paints * like a commit (strong, lane colour) and anchors its row; packages/git-graph reads * as a commit and exposes marker.folded / dots.folded; the desktop LaneGraph and the mobile GitGraphPanel draw a diamond; fixtures and the screenshot scenarios assert three diamonds at x=77 with no disc in those rows; both TUI guides name the glyph.

Verification

Run in a throwaway worktree at 6c05ae57a with the pinned 1.99.1 toolchain and ulimit -n 8192:

  • cargo fmt --all -- --check → clean
  • cargo check -p future-host -p future-tui --all-targets → clean
  • cargo clippy -p future-host -p future-tui --all-targets -- -D warnings → clean
  • cargo test -p future-host --lib git_history → 20 passed, 0 failed
  • cargo test -p future-tui --lib git → 55 passed, 1 ignored
  • desktop tsc --noEmit → clean; eslint on the four touched desktop files → clean
  • desktop vitest run src/features/git-history/GitHistoryPanel.test.tsx → 17 passed
  • @future-os/git-graph vitest via the CI invocation → 22 passed
  • mobile tsc --noEmit → clean; the mobile jest suite could not run locally because this checkout's mobile/node_modules is stale (@react-native/js-polyfills missing), so CI is the first run of it
  • make check-docs → 425 docs OK, 13 provider rows OK; screenshot scenario-fragment regression test → ok

User-visible changes

  • A commit folded into the sixth lane is drawn as * instead of o in the TUI text graph, and as a diamond instead of a disc in the desktop git-history panel and the mobile git-graph panel. Row, column and detail are unchanged. Revert: commit 958881e63.

The six-lane cap draws lines past the sixth inside the last column, so a
commit on one of them sat on a dot at a column that is not its own — the
picture read as one line carrying several commits, which is exactly what a
reader reported ("they look joined together").

A folded commit is now `*` instead of `o` (host and TUI), and the decoder
carries `folded` through to the two panels, which draw it as a diamond
instead of a disc. Nothing is dropped: the commit keeps its row, its place
in the sixth column and its detail.

- `host/src/git_history.rs`, `tui/src/workbench/git_panel.rs`: the glyph.
- `tui/src/workbench/screen.rs`: `*` is painted like a commit (strong, lane
  colour) and anchors its row's horizontal; the gutter-vocabulary guard now
  names the glyph set instead of blacklisting `*`.
- `packages/git-graph`: `*` is a commit; `marker.folded` / `dots.folded`.
- mobile `GitGraphPanel`, desktop `LaneGraph`: diamond (rotated square),
  half-diagonal `DOT_RADIUS + 1`, same lane colour.
- fixtures: the three folded rows of the ten-branch demo carry `*`; the
  folder's sixth-lane row keeps `o`, which is what shows the distinction.
- screenshot scenarios assert it geometrically: three diamonds, all at
  x=77, and no disc in those rows.

A folded merge is `*` too: the window edge cannot draw the elbow a merge
needs, so a ring there would promise a shape the row cannot show.
@huichen
huichen enabled auto-merge (squash) November 22, 2026 08:21
@huichen
huichen merged commit 27fa312 into main Nov 22, 2026
25 checks passed
@huichen
huichen deleted the pr/huichen branch November 22, 2026 08:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant