git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: Elijah Newren <newren@gmail.com>
Cc: Yuri Kanivetsky <yuri.kanivetsky@gmail.com>,
	Git Mailing List <git@vger.kernel.org>
Subject: Re: Why `git am -3` apply patches that don't normally apply?
Date: Tue, 05 Jul 2022 11:09:10 -0700	[thread overview]
Message-ID: <xmqqmtdnjut5.fsf@gitster.g> (raw)
In-Reply-To: <CABPp-BEkEKQZR=1duxSS4AVv9u5tnPk5CaLCM_fQWPbAqfSMxw@mail.gmail.com> (Elijah Newren's message of "Mon, 4 Jul 2022 12:23:49 -0700")

Elijah Newren <newren@gmail.com> writes:

> As per the documentation of -3:
>
>         When the patch does not apply cleanly, fall back on
>         3-way merge if the patch records the identity of blobs
>         it is supposed to apply to and we have those blobs
>         available locally.

I suspect that we would need to update this part, as the order of
"fall back" was swapped sometime in the recent past (and we have
fixed a few bugs that were introduced as fallouts).

Your description on how -3 works when it does the three-way based on
the concrete example was very clear and easy to understand, by the
way.

Thanks for writing it up.

  reply	other threads:[~2022-07-05 18:09 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-03 12:11 Why `git am -3` apply patches that don't normally apply? Yuri Kanivetsky
2022-07-04 19:23 ` Elijah Newren
2022-07-05 18:09   ` Junio C Hamano [this message]
2022-07-06  0:19     ` Yuri Kanivetsky

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=xmqqmtdnjut5.fsf@gitster.g \
    --to=gitster@pobox.com \
    --cc=git@vger.kernel.org \
    --cc=newren@gmail.com \
    --cc=yuri.kanivetsky@gmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).