Uh oh!
There was an error while loading. Please reload this page.
Branching - #2890
Conversation
@extrawurst Would love your feedback on this :) Quite large. OH! And I just noticed that I removed the missing docs lint, I'll add that back if we agree on this general direction. |
gogongxt
commented
Mar 24, 2026
LGTM |
| * fix extremely slow status loading in large repositories by replacing time-based cache invalidation with generation counter [[@DannyStoll1](https://github.com/DannyStoll1)] ([#2823](https://github.com/gitui-org/gitui/issues/2823)) | ||
| * fix panic when renaming or updating remote URL with no remotes configured [[@xvchris](https://github.com/xvchris)] ([#2868](https://github.com/gitui-org/gitui/issues/2868)) | ||
| ### Added | ||
| * Now with a graph view! |
There was a problem hiding this comment.
please match the ususal format
extrawurst
commented
Mar 29, 2026
philocalyst
commented
Mar 29, 2026
via email
Being precise here, the only difference I can see in the lack of a bottom connector? Or is there something else?
▰▰▰▰▰
Miles Wirth 🙃 … From: extrawurst ***@***.***>
Sent: 29 March 2026 11:53
To: gitui-org/gitui ***@***.***>
Cc: Miles Wirht ***@***.***>, Author ***@***.***>
Subject: Re: [gitui-org/gitui] Branching (PR #2890)
extrawurst left a comment (gitui-org/gitui#2890)
I think we need to improve the visualization still, this is the same point in time of the history in three different tools: gitui, tig and fork:
<img width="623" height="291" alt="Screenshot 2026-03-29 at 19 50 36" src="https://github.com/user-attachments/assets/a05fed09-ce18-4f55-8915-e143b37b01d3" />
<img width="392" height="326" alt="Screenshot 2026-03-29 at 19 50 27" src="https://github.com/user-attachments/assets/8669dbeb-604b-4d25-ba8c-de5aa701ac95" />
<img width="895" height="227" alt="Screenshot 2026-03-29 at 19 51 51" src="https://github.com/user-attachments/assets/5cf8535b-3ce6-44a2-944d-a33c81c548ce" />
--
Reply to this email directly or view it on GitHub:
#2890?email_source=notifications&email_token=A3MQBNB5QFY6DKIO5JS2ZSD4TFWKZA5CNFSNUABFM5UWIORPF5TWS5BNNB2WEL2JONZXKZKDN5WW2ZLOOQXTIMJVGA4DKNBWGE32M4TFMFZW63VGMF2XI2DPOKSWK5TFNZ2LK4DSL5RW63LNMVXHIX3POBSW4X3DNRUWG2Y#issuecomment-4150854617
You are receiving this because you authored the thread.
Message ID: ***@***.***> |
VojtaStanek
commented
Apr 1, 2026
I am looking forward to this change! By a quick look the source it seems like it works only with merge commits with 2 parents, but commit can have an arbitrary number of parents (see e.g. here). |
philocalyst
commented
Apr 1, 2026
@VojtaStanek Yes! Octopus merges! That's not covered here. I couldn't find an implementation that handles them in a way that maps well to streaming. They don't crash anything, and happen incredibly rarely. If someone is able to extend what I have here, they're welcome to; but it shouldn't block merging. |
cruessler
commented
Apr 7, 2026
philocalyst
commented
Apr 7, 2026
via email
No, that's just how they look :sad:.
Good points -- I also wonder if people like the pressed texts to the facets of the branch lines? I could implement that as well.
I think symbols... look cooler; but there are readability improvements we could aim for regardless, that these screenshots are making clear to me. The glyphs could expose be exposed as configuration.
▰▰▰▰▰
Miles Wirth 🙃 … From: Christoph Rüßler ***@***.***>
Sent: 07 April 2026 12:37
To: gitui-org/gitui ***@***.***>
Cc: Miles Wirht ***@***.***>, Author ***@***.***>
Subject: Re: [gitui-org/gitui] Branching (PR #2890)
cruessler left a comment (gitui-org/gitui#2890)
Thanks a lot for getting this started, that’s much appreciated! I just started reviewing the changes, but then I had a few more general questions.
In its current form, I find it hard to see merge commits and how they connect to their respective parents. The image below shows a comparison between this branch and `tig` in the `gitoxide` repository that has quite a few merge commits. Is there anything I need to set up to make merge commits more prominent? Does my terminal font need to have certain glyphs?
Also, in `tig`, vertical lines don’t get cut by horizontal ones, as opposed to `guitar`. I think I like `tig`’s approach better. What do you think?
<img width="3440" height="1412" alt="Screenshot_20260407_212543" src="https://github.com/user-attachments/assets/c224b4a6-6a01-4942-be2f-fef91d63d40a" />
--
Reply to this email directly or view it on GitHub:
#2890 (comment)
You are receiving this because you authored the thread.
Message ID: ***@***.***> |
extrawurst
commented
Apr 16, 2026
Not for now.
Also not relevant for now. Lets find a visual style thats a good default and add customization in a later PR. THis one is big enough as is.
I agree with this. we either find better symbols or go for the letter Furthermore I think we should use different colored lines for parallel branches like tig does for more clear separation. |
philocalyst
commented
Apr 17, 2026
![]() ![]() ![]() With the updates, the PR is now looking like the above. Is this a better direction? @extrawurst I plan to submit a follow-up PR with selection-based highlighting which I think will clear up the remaining vie |
balintbarna
commented
Apr 22, 2026
Hi all, if you need a reference for what looks good and works well in TUI then lazygit (go) and git-igitt (rust) are both very good at visualizing the graph. I think the table layout of lazygit makes more sense: short hash | timestamp | name | graph | (tags, branches) message it can also switch between --all mode and current branch https://github.com/jesseduffield/lazygit#commit-graph ![]() |
philocalyst
commented
Apr 22, 2026
When I looked at the algo's of git-gitt there was some issues around their design as a second-pass over a complete input, which is counter to the streaming design of gitui. Definitely still some issues I realize I miss when I review, I think there's still some issues with connecting pipes, but the tradeoffs of the algorithm feel solid to me. |
@philocalyst thanks for your reply. I don't have any insight on the code of the above mentioned projects, my comment is purely from a user perspective. I'm a software professional and my main way of interacting with git is lazygit, before that I used the integration in vs code with the very popular git graph extension and before that I used source tree. I also briefly tried gitkraken and more recently gitui. I use the CLI when I need to or when it's simpler. While lazygit has some serious bugs and I disagree with some of their decisions which make me miss git graph from vs code, it is my favourite tool so far, and a big part of that is their graph view, and even if the first version in gitui isn't equivalent, I would like to suggest it as inspiration for what it could become, in addition to the also fantastic git graph extension in vs code and the visually appealing git-igitt. |
philocalyst
commented
Apr 22, 2026
via email
I'm with you !!
Yeah I do plan to do follow-up PRs, just adding in more of these complex previews might have to be done on a second pass on just the active window.
▰▰▰▰▰
Miles Wirth 🙃 … From: balintbarna ***@***.***>
Sent: 22 April 2026 15:05
To: gitui-org/gitui ***@***.***>
Cc: Miles Wirht ***@***.***>, Mention ***@***.***>
Subject: Re: [gitui-org/gitui] Branching (PR #2890)
balintbarna left a comment (gitui-org/gitui#2890)
@philocalyst thanks for your reply. I don't have any insight on the code of the above mentioned projects, my comment is purely from a user perspective.
I'm a software professional and my main way of interacting with git is lazygit, before that I used the integration in vs code with the very popular git graph extension and before that I used source tree. I also briefly tried gitkraken and more recently gitui. I use the CLI when I need to or when it's simpler.
While lazygit has some serious bugs and I disagree with some of their decisions which make me miss git graph from vs code, it is my favourite tool so far, and a big part of that is their graph view, and even if the first version in gitui isn't equivalent, I would like to suggest it as inspiration for what it could become.
--
Reply to this email directly or view it on GitHub:
#2890?email_source=notifications&email_token=A3MQBNCKMUOFIA5ZN45NX3L4XE64LA5CNFSNUABFM5UWIORPF5TWS5BNNB2WEL2JONZXKZKDN5WW2ZLOOQXTIMZQGAZDKMRUHEYKM4TFMFZW63VHNVSW45DJN5XKKZLWMVXHJNLQOJPWG33NNVSW45C7N5YGK3S7MNWGSY3L#issuecomment-4300252490
You are receiving this because you were mentioned.
Message ID: ***@***.***> |
cruessler
commented
Apr 27, 2026
@philocalyst Thanks for the changes! I’ve now started the proper first review which should be ready by today or tomorrow if all goes according to plan! 😀 |
philocalyst
commented
Apr 27, 2026
via email
Thanks so much :)
▰▰▰▰▰
Miles Wirth 🙃 … From: Christoph Rüßler ***@***.***>
Sent: 26 April 2026 23:24
To: gitui-org/gitui ***@***.***>
Cc: Miles Wirht ***@***.***>, Mention ***@***.***>
Subject: Re: [gitui-org/gitui] Branching (PR #2890)
cruessler left a comment (gitui-org/gitui#2890)
@philocalyst Thanks for the changes! I’ve now started the proper first review which should be ready by today or tomorrow if all goes according to plan! 😀
--
Reply to this email directly or view it on GitHub:
#2890 (comment)
You are receiving this because you were mentioned.
Message ID: ***@***.***> |
peso
commented
Apr 27, 2026
Hi there. I'm still working on getting git-graph, now gleisbau, into gitui. The speed requirement from gitui can be solved by splitting the global branch trace algorithm off to a background thread, and then start at head. This will feel as if it starts instantly, but it will traverse the entire repo in due time. The split also addresses the memory issue seen in the gitui+gitgraph prototype from about a year go. This is a major refactoring, so it will take some time. git-igitt is part of the git-bahn family and uses git-graph/gleisbau under the hood. I think it is a good idea to get a graph feature into gitui as soon as possible. Everybody wants it. Maybe gleisbau can produce a visual improvement, but the major step is simply getting a graph. Congratulations to @philocalyst for reaching that goal. |
cruessler
left a comment
There was a problem hiding this comment.
I’m sorry it’s taking so long! In order to not make you wait longer, I’m now sending you my first batch of comments, hoping they are already useful. As soon as I’m done with the next batch, you’ll get the next round of comments. I hope that works for you!
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
philocalyst
commented
May 23, 2026
Balls back in your court! @cruessler |
cruessler
commented
Jun 8, 2026
Really sorry it’s taking so long, I should be able to devote some time to this PR this week as I don’t have too many other obligations. |
philocalyst
commented
Jun 8, 2026
@cruessler Appreciated! Have another PR I've been sitting on for LFS, but didn't want to overwhelm the team -- so I'll be monitoring my github notifications closely to make sure this week isn't wasted!! |
cruessler
left a comment
There was a problem hiding this comment.
I’m slowly getting myself familiar with the PR, in order to make sure I actually understand myself what is going on. 😀 I’ve got a couple of questions and remarks, some more fundamental than others. I’m also going to push minor refactorings that don’t warrant a comment to your branch as well, in order to make some areas more idiomatic. I hope that’s ok, if not, please let me know!
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
philocalyst
commented
Jun 13, 2026
okay @cruessler you inspired me to do a pretty big refactor so sorry for the delay here! put a ton of effort into reducing the amount of redundant work as far as both clones and passing through the same commits/lanes twice or more. should be totally lazy as far as the graph goes, which i'm very happy to report! there's also a set of tests that should test the basics... (disclosure that i used $llm for the test writing, let me know if this goes against a policy and i will rewrite!) Also I kind of overpromised with stashes, although I will do in a follow-up if all goes well :) |
overly pessimistic collapsing rmeoved
philocalyst
commented
Jul 27, 2026
Fixed conflicts ! |
cruessler
left a comment
There was a problem hiding this comment.
This is a partial review (as I want to spend some time with friends now 😀). I’m leaving it, hoping to unblock you at least a bit. @philocalyst Again, thanks for your efforts!
From what I can tell, the PR is already in a good state. I tried it in my copy of the gitoxide repository which has a few interesting merges, and I didn’t spot any issues.
This comes with a few caveats, though:
- Since the PR was force-pushed, I was not able to pick up the review where I had left off after the previous one. This makes it harder to reconcile what’s new and what I’ve already seen which requires extra effort to review.
- This is a very large PR. I can manage to review maybe 700 lines per hour, but there’s limits to my spare time, in particular to my ability to dedicate a few hours uninterrupted to reviewing code. :-)
In light of that, I’m worried that I’m blocking this PR from moving forward. We might want to consider adopting a different strategy for getting it merged, such as merging behind a feature flag/an option and then finding the remaining issues. Another option would be to try and write more test cases and try to cover this feature as completely as reasonably possible.
@extrawurst What do you think?
| impl Default for Buffer { | ||
| fn default() -> Self { | ||
| Self::new() | ||
| } | ||
| } |
There was a problem hiding this comment.
You might have missed this comment.
| } | ||
| pub fn update(&mut self, new_chunk: &Chunk) { | ||
| // Phase 1: place the new chunk into the lane array. |
There was a problem hiding this comment.
You might have missed this comment.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
cruessler
left a comment
There was a problem hiding this comment.
New batch of comments. I expect to be able to have more time tomorrow as I’ll be on a train for a couple of hours. I want to spend them on wrapping up the review!
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
philocalyst
commented
Jul 28, 2026
Thank you SO much for your review! Your thoroughness is deeply admired -- it's humbling to fix these mistakes. As far as merge strategy goes, I am okay with writing more test-cases. Not really a fault of anyone in particular, but the response times in this project are measured in weeks/months in my experience, and I would rather not have to justify the removal of the flag-gating to eyes months removed (or have you guys have to continously re-acquaint). |
philocalyst
commented
Jul 28, 2026
And apologies about the force push, have been doing a lot of work on nixpkgs where it's preferred. I believe github preserves the original, but if you would like to see, I have it all in my reflog. |
cruessler
left a comment
There was a problem hiding this comment.
Another batch of comments. There’s only 7 files left to review now, most importantly asyncgit/src/revlog.rs and src/components/commitlist.rs.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
| parents: c | ||
| .parents() | ||
| .take(2) | ||
| .map(|p| CommitId(p.id())) | ||
| .collect(), |
There was a problem hiding this comment.
I haven’t gotten yet to profiling this addition against current master. It’s on my list, though.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
still mostly strict...
philocalyst
commented
Aug 11, 2026
@cruessler All good? |








This Pull Request fixes/closes#81.
It changes the following:
I followed the checklist:
make checkwithout errors