Thread (1 message) 1 message, 1 author, 2016-06-15

Re: git-gui: more issues with diff parsing

From: Junio C Hamano <hidden>
Date: 2016-06-15 22:45:21

"Shawn O. Pearce" [off-list ref] writes:
Notice how we get two diffs for the same file?  That's why git-gui
is choking on this particular change.  It expected only one diff
for the path it gave to Git.  It got two back.  In cases like this
we may not be able to support line or hunk application as the patch
is really two different patches against that path.  :-|
quoted
The following patch seems to fix this particular issue, but I don't think
it's the right fix...
I don't think that is the right fix, but the one that I just tried to
write to do clear_diff when we see the second diff --git line didn't
work either.  Plus we probably need to disable the hunk apply code.
You will have the same issue not for submodules, too.  A typechange has
always been expressed as delete followed by create.

Probably you already have learned the nature of change (i.e. create?
modify? delete? typechange?) when you populate the list of files with
changes that could be staged, which means by the time the user picks from
the liast you already know if it is a typechange.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help