Re: [PATCH] git-apply: allow empty patch text
- From
Junio C Hamano <gitster@pobox.com>
- Date
- Apr 27, 2021, 06:28 UTC
- Message-ID
- <xmqq7dkofdgg.fsf@gitster.g>
- In-Reply-To
- <20210427054632.GA31347@dcvr>
Eric Wong <e@80x24.org> writes:
> I fear this change can cause errors in pipelines to go > undetected (since "set -o pipefail" is not POSIX). > In my experience, zero-byte files is also a common failure mode > for some filesystems, even after fsck marked them as clean.
Thanks for saving me time to say it.
It would be a grave regression to any workflow automation to change the behaviour to silently succeed a non-patch application as a noop. And it does not take filesystem corruption.
Some people seem to gpg sign their patches sent to the list, which is not very useful at this point as I don't bother to collect their public keys anyway, but feeding such a piece of e-mail from GNUS to "git am -s" takes "\M-i r |" prefix instead of the regular "|" to "pipe the message to an external command" to properly get it processed. I was saved by the "empty input is wrong" behaviour a number of times.