Skip to content

Use more widely-supported Unicode symbols for the commit graph - #5573

Merged
stefanhaller merged 1 commit into
masterfrom
better-commit-graph-symbols
May 4, 2026
Merged

stefanhaller merged 1 commit into
masterfrom
better-commit-graph-symbols

Conversation

@stefanhaller

Copy link
Copy Markdown
Collaborator

The commit graph used '⏣' (U+23E3 BENZENE RING WITH CIRCLE) for merge commits and '◯' (U+25EF LARGE CIRCLE) for regular commits. Both have very poor coverage in popular monospace fonts:

  • '⏣' lives in the Misc Technical block and is essentially absent from every common monospace font (Source Code Pro, JetBrains Mono, Fira Code, Cascadia Code, Hack, Iosevka, Menlo, Consolas, Monaco, IBM Plex Mono, Ubuntu Mono, Noto Sans Mono, Inconsolata). It is always drawn from a system fallback font.
  • '◯' is the late-addition LARGE CIRCLE codepoint. It is present in some fonts (Cascadia, Fira Code, Hack, Iosevka, Menlo, Noto Sans Mono) but missing from many others, including Source Code Pro and most Nerd Font derivatives based on it.

This is why the graph renders inconsistently across platforms even when the same monospace font is configured: each OS picks a different fallback font (Apple Symbols on macOS, Segoe UI Symbol on Windows, Noto/DejaVu/Symbola on Linux), and the substituted glyphs differ in shape, weight, and advance width. '◯' is also East Asian Ambiguous width, so some terminals render it wider than one cell, exaggerating the misalignment.

Replace the symbols with codepoints from the foundational 1991 Geometric Shapes block, which has far broader font coverage:

  • Merge: '◎' U+25CE BULLSEYE -- concentric circles, the visually closest cousin to the previous benzene-ring glyph.
  • Commit: '○' U+25CB WHITE CIRCLE -- the same hollow-circle silhouette as before, just a more universally available codepoint.

The new symbols are present in the font directly in significantly more cases; and when fallback is still required, they are universally well-drawn (unlike '⏣', which many fallback fonts also lack).

I also considered choosing suitable nerd font symbols for those who are using nerd fonts, on the assumption that these must work better because they are guaranteed to be in the font and no fallback font substitution is necessary; several suitable icons could be considered, e.g. nf-cod-circle_large or nf-md-circle_double. Surprisingly, these didn't work well, and the reason is that (at least in the font I am using) these are defined with a glyph width that is wider than their advance width, which means they draw in different sizes depending on whether they are followed by a space or not. The glyphs we picked above don't have this problem.

And finally, I considered adding config options so that users with weird fonts can pick symbols that work well for them. I would like to avoid having to do this though; ideally we should be able to make a choice that works well for everybody.

The commit graph used '⏣' (U+23E3 BENZENE RING WITH CIRCLE) for merge
commits and '◯' (U+25EF LARGE CIRCLE) for regular commits. Both have
very poor coverage in popular monospace fonts:

- '⏣' lives in the Misc Technical block and is essentially absent from
  every common monospace font (Source Code Pro, JetBrains Mono, Fira
  Code, Cascadia Code, Hack, Iosevka, Menlo, Consolas, Monaco, IBM
  Plex Mono, Ubuntu Mono, Noto Sans Mono, Inconsolata). It is always
  drawn from a system fallback font.
- '◯' is the late-addition LARGE CIRCLE codepoint. It is present in
  some fonts (Cascadia, Fira Code, Hack, Iosevka, Menlo, Noto Sans
  Mono) but missing from many others, including Source Code Pro and
  most Nerd Font derivatives based on it.

This is why the graph renders inconsistently across platforms even
when the same monospace font is configured: each OS picks a different
fallback font (Apple Symbols on macOS, Segoe UI Symbol on Windows,
Noto/DejaVu/Symbola on Linux), and the substituted glyphs differ in
shape, weight, and advance width. '◯' is also East Asian Ambiguous
width, so some terminals render it wider than one cell, exaggerating
the misalignment.

Replace the symbols with codepoints from the foundational 1991
Geometric Shapes block, which has far broader font coverage:

- Merge: '◎' U+25CE BULLSEYE -- concentric circles, the visually
  closest cousin to the previous benzene-ring glyph.
- Commit: '○' U+25CB WHITE CIRCLE -- the same hollow-circle silhouette
  as before, just a more universally available codepoint.

The new symbols are present in the font directly in significantly
more cases; and when fallback is still required, they are universally
well-drawn (unlike '⏣', which many fallback fonts also lack).

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@stefanhaller
stefanhaller force-pushed the better-commit-graph-symbols branch from a8e63c8 to 35d3659 Compare May 4, 2026 11:06
@stefanhaller
stefanhaller enabled auto-merge May 4, 2026 11:06
@stefanhaller
stefanhaller merged commit 59b9b59 into master May 4, 2026
13 checks passed
@stefanhaller
stefanhaller deleted the better-commit-graph-symbols branch May 4, 2026 11:09
social4hyq pushed a commit to social4hyq/homebrew-core that referenced this pull request Sep 20, 2026
lazygit 0.62.0

Created-by: HarmonybrewBot
Commit-by: HarmonybrewBot
Merged-by: HarmonybrewBot
Description: Created by `brew bump`

---

Created with `brew bump-formula-pr`.<details>
  <summary>release notes</summary>
  <pre>The big change in this release is what I have been referring to as the "keybinding revamp": it allows you to use richer keybindings than the few that were available before; see [Custom_Keybindings.md](https://github.com/jesseduffield/lazygit/blob/master/docs/keybindings/Custom_Keybindings.md) for details. It also describes a new keybinding syntax that is a bit more intuitive than the previous `<c-x>` notation (but the old one is still supported for backwards compatibility).

Note the section about Terminal compatibility in that document; not all terminals support the new protocol equally well, so it may be a good idea to switch to one that does.

Breaking change: The default keybinding for submitting a commit from the commit description editor has changed from alt-enter to command-enter on Mac, or ctrl-enter on Linux and Windows; these are the same bindings that are used in many multi-line edit field situations, e.g. in GitHub comments. Unfortunately these are not supported by all terminals; see the above-mentioned [terminal compatibility](https://github.com/jesseduffield/lazygit/blob/master/docs/keybindings/Custom_Keybindings.md#terminal-compatibility) for more on that. If you want to revert this change, you can do so by adding the following to your config:

```yml
keybinding:
  universal:
    confirmInEditor: [<alt+enter>, <ctrl+s>]
```

The complete list of changes follows:



<!-- Release notes generated using configuration in .github/release.yml at v0.62.0 -->

## What's Changed
### Enhancements 🔥
* Retry on ref lock errors during fetch/pull by @majiayu000 in jesseduffield/lazygit#5161
* Preserve whitespace when remembering commit message by @stefanhaller in jesseduffield/lazygit#5528
* Define PR colors as hex colors to make them the same as GitHub's by @stefanhaller in jesseduffield/lazygit#5480
* Revamp keybinding mechanism to support richer keybindings (e.g. `ctrl-alt-shift-x `) by @stefanhaller in jesseduffield/lazygit#5563
* Platform-specific edit bindings for move-by-word and backspace-word by @stefanhaller in jesseduffield/lazygit#5564
* Change canonical keybinding syntax (`<ctrl+a>` instead of `<c-a>`) by @stefanhaller in jesseduffield/lazygit#5565
* Use more widely-supported Unicode symbols for the commit graph by @stefanhaller in jesseduffield/lazygit#5573
* Show push URLs for remotes that have any by @stefanhaller in jesseduffield/lazygit#5576
* Support GitHub Enterprise for the Pull Requests feature by @stefanhaller in jesseduffield/lazygit#5596
* Allow keybindings to configure more than one key by @stefanhaller in jesseduffield/lazygit#5634
* Add `<alt+up>`/`<alt+down>` as alternate keybindings for moving commits up/down by @stefanhaller in jesseduffield/lazygit#5637
* Add support for git flow using the git-flow-next tool by @hmaddocks in jesseduffield/lazygit#5288
### Fixes 🔧
* Fix copying a file's absolute path when running in a linked worktree by @stefanhaller in jesseduffield/lazygit#5523
* Preserve commit message when quitting while the commit message panel is open by @stefanhaller in jesseduffield/lazygit#5524
* Stop showing cached PRs when we no longer have a base remote by @stefanhaller in jesseduffield/lazygit#5543
* If multiple remotes exist but only one is a Github remote, pick it without prompting by @stefanhaller in jesseduffield/lazygit#5544
* Fix cherry-picking a range selection of commits by @stefanhaller in jesseduffield/lazygit#5599
* Dont log GitHub PR fetching errors to the Command log by @stefanhaller in jesseduffield/lazygit#5600
* Avoid auto-forwarding main branches checked out in other worktrees by @stefanhaller in jesseduffield/lazygit#5621
* Fix cycling pagers when main view is focused by @stefanhaller in jesseduffield/lazygit#5639
### Maintenance ⚙️
* Bump samber.lo to latest version by @stefanhaller in jesseduffield/lazygit#5545
* Bump github.com/kyokomi/emoji/v2 from 2.2.8 to 2.2.13 by @dependabot[bot] in jesseduffield/lazygit#5481
* Bump github.com/gookit/color from 1.4.2 to 1.6.0 by @dependabot[bot] in jesseduffield/lazygit#5482
* Bump github.com/sirupsen/logrus from 1.9.3 to 1.9.4 by @dependabot[bot] in jesseduffield/lazygit#5483
* Bump dario.cat/mergo from 1.0.1 to 1.0.2 by @dependabot[bot] in jesseduffield/lazygit#5484
* Bump peter-evans/create-pull-request from 8.1.0 to 8.1.1 by @dependabot[bot] in jesseduffield/lazygit#5514
* Bump goreleaser/goreleaser-action from 7.0.0 to 7.1.0 by @dependabot[bot] in jesseduffield/lazygit#5529
* Bump actions/github-script from 8 to 9 by @dependabot[bot] in jesseduffield/lazygit#5515
* Bump golang.org/x/sys from 0.42.0 to 0.43.0 by @dependabot[bot] in jesseduffield/lazygit#5548
* Copy gocui into lazygit repo by @stefanhaller in jesseduffield/lazygit#5561
* Update to tcell v3 by @stefanhaller in jesseduffield/lazygit#5562
* Clear LC_* env vars when running LANG tests by @AntoineGS in jesseduffield/lazygit#5568
* Fix failing windows tests by @stefanhaller in jesseduffield/lazygit#5574
* Fix new gopls linter warnings by @stefanhaller in jesseduffield/lazygit#5580
* Disable gh telemetry when running integration tests by @stefanhaller in jesseduffield/lazygit#5587
* Fix the check_for_fixups.sh script again by @stefanhaller in jesseduffield/lazygit#5590
* Add script to preview release notes by @stefanhaller in jesseduffield/lazygit#5620
* Bump github.com/gookit/color from 1.6.0 to 1.6.1 by @dependabot[bot] in jesseduffield/lazygit#5586
* Bump github.com/sahilm/fuzzy from 0.1.1 to 0.1.2 by @dependabot[bot] in jesseduffield/lazygit#5606
* Bump golang.org/x/sys from 0.43.0 to 0.45.0 by @dependabot[bot] in jesseduffield/lazygit#5607
* Bump github.com/gdamore/tcell/v3 from 3.3.0 to 3.4.0 by @dependabot[bot] in jesseduffield/lazygit#5618
* Bump goreleaser/goreleaser-action from 7.1.0 to 7.2.2 by @dependabot[bot] in jesseduffield/lazygit#5619
### Docs 📖
* Fix undo shortcut in Undoing.md by @stefanhaller in jesseduffield/lazygit#5640
* Update docs and schema for release by @stefanhaller in jesseduffield/lazygit#5645
### I18n 🌎
* Update translations from Crowdin by @stefanhaller in jesseduffield/lazygit#5644
### Performance Improvements 📊
* Improve performance of showDivergenceFromBaseBranch by @AntoineGS in jesseduffield/lazygit#5536
* Redraw only the spinner when nothing else has changed by @AntoineGS in jesseduffield/lazygit#5571
* Improve inline spinner performance by @stefanhaller in jesseduffield/lazygit#5592

## New Contributors
* @majiayu000 made their first contribution in jesseduffield/lazygit#5161
* @AntoineGS made their first contribution in jesseduffield/lazygit#5536
* @hmaddocks made their first contribution in jesseduffield/lazygit#5288

**Full Changelog**: jesseduffield/lazygit@v0.61.1...v0.62.0

</pre>
  <p>View the full release notes at <a href="https://github.com/jesseduffield/lazygit/releases/tag/v0.62.0">https://github.com/jesseduffield/lazygit/releases/tag/v0.62.0</a>.</p>
</details>
<hr>

See merge request: Harmonybrew/homebrew-core!8880
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant