threads / discuss / 26242

No way to resolve git am conflicts.

Subject: No way to resolve git am conflicts.

## tl;dr

3 messages between Jan 8, 2011 and Jan 8, 2011.

replies: 2people: 2as markdown or json

Stephen Kelly· Jan 8, 2011, 13:11 UTC · lore
kde-devel@bishop:~/dev/src/git{master}$ curl -o the.patch 
http://download.gmane.org/gmane.comp.version-control.git/164809/164810 && 
git am the.patch
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  
Current
                                 Dload  Upload   Total   Spent    Left  
Speed
100 10438    0 10438    0     0  12046      0 --:--:-- --:--:-- --:--:-- 
13451
Applying: Introduce new configuation option to override committer 
information
error: patch failed: builtin/commit.c:1352
error: builtin/commit.c: patch does not apply
Patch failed at 0001 Introduce new configuation option to override committer 
information
When you have resolved this problem run "git am --resolved".
If you would prefer to skip this patch, instead run "git am --skip".
To restore the original branch and stop patching run "git am --abort".
Qt( 4.7 ) KDE ( 4.6 ) 
kde-devel@bishop:~/dev/src/git{master}$ git diff
Qt( 4.7 ) KDE ( 4.6 ) 
kde-devel@bishop:~/dev/src/git{master}$ git status
# On branch master
# Untracked files:
#   (use "git add <file>..." to include in what will be committed)
#
#       p.patch
#       the.patch
nothing added to commit but untracked files present (use "git add" to track)
Qt( 4.7 ) KDE ( 4.6 ) 
kde-devel@bishop:~/dev/src/git{master}$ 
As git status doesn't tell me what the conflict is, I can't resolve it.
Jonathan Nieder· Jan 8, 2011, 16:36 UTC · re: Stephen Kelly · lore

Re: No way to resolve git am conflicts.

Stephen Kelly wrote:
> git am the.patch
[...]
Show 10 quoted lines
> Applying: Introduce new configuation option to override committer 
> information
> error: patch failed: builtin/commit.c:1352
> error: builtin/commit.c: patch does not apply
> Patch failed at 0001 Introduce new configuation option to override committer 
> information
> When you have resolved this problem run "git am --resolved".
> If you would prefer to skip this patch, instead run "git am --skip".
> To restore the original branch and stop patching run "git am --abort".
> $ git diff
[...]
> As git status doesn't tell me what the conflict is, I can't resolve it.

Have you tried "git am -3" or "git am --reject" (after "git am --abort")?

I agree that the hints printed are suboptimal in this case. Please feel free to make them better if you have time for it. :)

Stephen Kelly· Jan 8, 2011, 19:21 UTC · re: Jonathan Nieder · lore

Re: No way to resolve git am conflicts.

Jonathan Nieder wrote:
Show 19 quoted lines
> Stephen Kelly wrote:
> 
>> git am the.patch
> [...]
>> Applying: Introduce new configuation option to override committer
>> information
>> error: patch failed: builtin/commit.c:1352
>> error: builtin/commit.c: patch does not apply
>> Patch failed at 0001 Introduce new configuation option to override
>> committer information
>> When you have resolved this problem run "git am --resolved".
>> If you would prefer to skip this patch, instead run "git am --skip".
>> To restore the original branch and stop patching run "git am --abort".
>> $ git diff
> [...]
>> As git status doesn't tell me what the conflict is, I can't resolve it.
> 
> Have you tried "git am -3" or "git am --reject" (after "git am
> --abort")?
git am -3 worked, thanks.
> 
> I agree that the hints printed are suboptimal in this case.  Please
> feel free to make them better if you have time for it. :)

← back to recent threads