git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Why does git-status suggest different commands to unstage files depending on whether there is a commit yet or not?
@ 2025-09-16 20:29 Anselm Schüler
  2025-09-16 20:34 ` Anselm Schüler
  2025-09-16 20:52 ` D. Ben Knoble
  0 siblings, 2 replies; 7+ messages in thread
From: Anselm Schüler @ 2025-09-16 20:29 UTC (permalink / raw)
  To: git

After a new repository has been created, before a commit has been made, 
when files are staged, git-status suggests using git-rm to unstage 
files: $ git status [...] No commits yet Changes to be committed:   (use 
"git rm --cached <file>..." to unstage) [...] After a commit has been 
made, git-status suggests using git-restore instead: $ git status [...] 
Changes to be committed: (use "git restore --staged <file>..." to 
unstage) [...] Why is this the case?


^ permalink raw reply	[flat|nested] 7+ messages in thread
[parent not found: <8e1905c7-7744-444f-9a39-ca809edb6896@anselmschueler.com>]

end of thread, other threads:[~2025-09-17 15:33 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-09-16 20:29 Why does git-status suggest different commands to unstage files depending on whether there is a commit yet or not? Anselm Schüler
2025-09-16 20:34 ` Anselm Schüler
2025-09-16 20:48   ` Junio C Hamano
2025-09-16 20:52 ` D. Ben Knoble
2025-09-17 12:12   ` Junio C Hamano
2025-09-17 15:33     ` D. Ben Knoble
     [not found] <8e1905c7-7744-444f-9a39-ca809edb6896@anselmschueler.com>
2025-09-16 21:51 ` Fwd: " Anselm Schüler
2025-09-17  8:03   ` Chris Torek

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).