Re: Repost: Inconsistent Behavior in 'git add' (git 2.52.0)?
- From
Jon Forrest <nobozo@gmail.com>
- Date
- Jan 18, 2026, 17:50 UTC
- Message-ID
- <c51367f1-9ce2-4580-9f7c-4b1adc989582@gmail.com>
- In-Reply-To
- <xmqq8qdydddl.fsf@gitster.g>
Thanks for your response. This is indeed a very minor issue.
On 1/15/26 8:55 AM, Junio C Hamano wrote:
> It is plausible to teach "git add" to treat paths that are > explicitly named on the command line (as opposed to the paths that > are discovered due to recursion) differently, but that would be a > new feature, not a bugfix, I would think.
Agreed. I had been thinking of 'git add' as a kind of database transaction, where either everything happens, or nothing happens.
An excluded file isn't considered the same type of error as an invalid file, which is fine as long as a user is aware of this behavior. The fact that 'git add' warns about ignored files helps.
Again, this is a tiny, tiny issue.
Cordially, Jon Forrest