On Wed, Oct 13, 2021 at 07:54:17PM +0200, Uwe Brauer wrote: [...] > Suppose I change three files (out of 10 in my repository), then > > git status > > Would tell me that three files are modified. > > I then can either > > 1. Commit all changes in one go > > 2. Or running a commit interactively, like > > a. Commit all changes in file 1. > > b. 50 % in file 2 > > c. 0% in file 3 > > I don't see any other possibilities (or I miss something fundamentally > here). > > I am asking this, because this is the way mercurial works[1], and it does > not have a staging area (or cache or index). > > So are we talking about the same functionality, just differently > implemented or is there something I miss?
If you're talking about hg commit --interactive which was previously available as an extension called "record", then yes, it appears to be roughly the same thing. The difference appears in that Git "exposes" that area which holds the state of the commit being prepared. IMO, one of the better explanation of this concept is to imagine the three trees - as in filesystem trees - manipulated by several commands [1]. Persons who prefer listening to reading could watch [2] by the same author. 1. https://git-scm.com/book/en/v2/Git-Tools-Reset-Demystified 2. https://www.infoq.com/presentations/A-Tale-of-Three-Trees/ -- You received this message because you are subscribed to the Google Groups "Git for human beings" group. To unsubscribe from this group and stop receiving emails from it, send an email to git-users+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/git-users/20211014100346.wgqxls5ze5p56nsd%40carbon.