From: Johannes Sixt Date: Thu, 18 Sep 2025 06:56:55 GMT Subject: Re: Fwd: Why does git-status suggest different commands to unstage files depending on whether there is a commit yet or not? Message-ID: <42250bbc-95f1-4f15-825e-66fbafb0b061@kdbg.org> In-Reply-To: Am 16.09.25 um 23:51 schrieb Anselm Schüler: > [...] I > would’ve assumed git-rm simply removes the file and “writes” that > removal to the staged changes. This seems to be what y’all are > describing. But with that suggestion, I was confused, because I assumed > git-rm there would be equivalent in some sense to git-restore in a > repository with commits. You seem to think that `git rm` removes a *change*. This leads me to believe that you think of commits as a set of *changes*. But this is the wrong mental model. A commit is a complete state of the project, and the index ("stage") is the complete project state that is going into the next commit. `git rm` removes a file, not a change. -- Hannes