git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: Can we do better than "git checkout/add -p"

From
Patrick Steinhardt <ps@pks.im>
Date
Aug 10, 2026, 08:45 UTC
Message-ID
<anmPq_WN33chIEhL@pks.im>
In-Reply-To
<26c2f7e0-03ef-4c45-8175-adcc2e0395ac@haller-berlin.de>
On Mon, Aug 10, 2026 at 09:26:55AM +0200, Stefan Haller wrote:
Show 17 quoted lines
> On 10.08.26 08:03, Patrick Steinhardt wrote:
> > I've been playing around with the thought of introducing ncurses-based
> > interfaces into Git. I've been mostly thinking about git-history(1) here
> > so that you can just move commits around, squash them together, drop
> > them and so on. But I think fancy stuff like TUIs can also be applied to
> > other parts of Git, as well, to make things a bit more visual to our
> > users and, as a consequence, easier to use.
> 
> That sounds a whole lot like lazygit to me [1]; it does all those things
> in a rather intuitive way, including Junio's original use case of
> selecting a hunk and staging or discarding it.
> 
> Is it really worth adding such functionality to core git? I like the
> idea of tools specializing on what they do well; core git on providing
> the core functionality, GUI tools on presenting it in a UI.
> 
> [1] https://github.com/jesseduffield/lazygit

I think it depends. There are lots of users out there who use core Git, only, and we often hear complaints from this class of users that Git makes common workflows way too complex. I certainly think that we should up our game and try to make such common workflows easier to wield. Tools like JJ demonstrate that there are a bunch of improvements that we can do, and many of those aren't even that hard to implement.

So If we see that there are use cases where core Git itself is lacking and where the consequence is a bad user experience for common workflows then I think that we should plug that gap in core Git itself.

That being said, I don't think we should get into the business of building a full UI, as that feels like a can of worms indeed. Adding something like a user interface around hunk selection certainly feels like core functionality that I think should be in scope for Git. Whether a full history-editing user interface should be part of core Git may be a different question though, as this is getting significantly closer to a full UI.

Patrick
Previous: Stefan HallerNext: Junio C Hamano
Message 9 of 15 in “Can we do better than "git checkout/add -p"”
  1. Junio C HamanoAug 7, 2026
  2. Christian CouderAug 7, 2026
  3. D. Ben KnobleAug 7, 2026
  4. Junio C HamanoAug 7, 2026
  5. D. Ben KnobleAug 7, 2026
  6. Junio C HamanoAug 7, 2026
  7. Patrick SteinhardtAug 10, 2026
  8. Stefan HallerAug 10, 2026
  9. Patrick SteinhardtAug 10, 2026
  10. Junio C HamanoAug 10, 2026
  11. Patrick SteinhardtAug 11, 2026
  12. Johannes SchindelinAug 12, 2026
  13. Jeff KingAug 12, 2026
  14. Junio C HamanoAug 12, 2026
  15. Junio C HamanoAug 12, 2026

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.