Thread (7 messages) flat view 7 messages, 3 authors, 2016-06-15

Re: git-apply{,mbox,patch} should default to --unidiff-zero

From: Johannes Schindelin <hidden>
Date: 2016-06-15 22:43:19

Hi,

On Fri, 6 Jul 2007, Adrian Bunk wrote:
On Fri, Jul 06, 2007 at 02:51:07AM +0100, Johannes Schindelin wrote:
quoted
On Fri, 6 Jul 2007, Adrian Bunk wrote:
quoted
You must do something like "diff -U0" or manually editing patches 
for creating such patches, and that's very unusual.
The point is that the _committer_ is not necessarily involved in that 
business.
BTW this still holds true, and you have not addressed that.  It really is 
a serious issue.  "git apply" is a committer's tool.  So it should help 
the committer.
quoted
And "git apply" is strict for a reason. It catches possibly unwanted 
things much earlier than patch. I _want_ to be warned that somebody is 
introducing some code at a certain position, which might, or might not 
be correct. apply has no way to tell, since there is no context to at 
least minimally verify.
...
That's wrong.

My use cases are replacing or deleting lines.
That is _your_ use case.
In these cases there is context in the deleted lines that is already 
being verified even with --unidiff-zero.
With --unidiff-zero, also _adding_ lines will be handled as if there were 
no problem.

Yes, in your case it fixes a problem.

Yet, in other cases it introduces a problem.

Okay?

Ciao,
Dscho
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help