Re: [PATCH 0/2] Making "git commit" to mean "git commit -a".
From: Junio C Hamano <hidden>
Date: 2016-08-11 19:33:40
Linus Torvalds [off-list ref] writes:
On Thu, 30 Nov 2006, Junio C Hamano wrote:quoted
I sense that you are inviting me to argue for reverting the other "git commit" braindead which is spelled "--only" (and worse yet, it is the default). I am very tempted.I actually really like the current defaults for "git commit".
Hmmm. I did not make my judgement based on what the command did in the ancient _original_ version. The --only behaviour being totally different from others (from "index is the only thing that matters" point of view) was what bothered me. It did not feel logical. However, if you put it this way:
I like the fact that when you do "git commit filename", it really will commit _only_ that file, not the other files you added. It's logical.
that makes tons of sense. What's "logical" largely depends on how things ought to behave in the mental model, and the mental model you would form largely depends on how things are explained to you.