From: Steven Grimm <koreth@midwinter.com>
To: Johannes Schindelin <Johannes.Schindelin@gmx.de>
Cc: git@vger.kernel.org
Subject: Re: [RFC] Replace rebase with filtering
Date: Tue, 16 Jan 2007 11:43:35 -0800 [thread overview]
Message-ID: <45AD2AE7.2010908@midwinter.com> (raw)
In-Reply-To: <45AD2568.4040408@midwinter.com>
Steven Grimm wrote:
> Johannes Schindelin wrote:
>> I had the impression that the use of "--ignore-if-in-upstream" in
>> git-rebase avoids exactly this case: re-applying changes which are
>> already in upstream.
> Where's that option documented? The manpage makes no mention of it at
> all.
Ah, okay, poking around in the git-rebase source, I see you mean that
git-format-patch is called with that option. Gotcha. The problem is that
after a rebase, the revisions in question *aren't* in the upstream.
Here's my understanding of why. Say I have this in my integration
repository:
a---b---c---d (master)
\
e---f---g (integration)
Now, I rebase the integration branch onto master:
a---b---c---d
\
e'---f'---g'
The problem is that, since e' contains all the changes in e *and* in
b/c/d, it does not have the same SHA1 as the original e revision, nor in
fact the same hash as any of the revisions in the pre-rebase tree. And
after rebase succeeds, it wipes the original e, f, and g from the
history of the integration branch.
When a clone fetches e', f', and g' from this repo and tries to rebase
onto the integration branch, git-format-patch will think b, c, and d are
new (correct) but also that e', f', and g' are new. Since they have
previously unknown hashes and there's no record of the original e, f,
and g or their relation to the new revisions -- at least, no record that
gets pulled down to the clone when it fetches -- there's no way for
git-format-patch to know that it has already applied those changes.
As always, correct me if I'm wrong -- that's my understanding of the
problem with rebasing in a parent repository.
-Steve
next prev parent reply other threads:[~2007-01-16 19:43 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-01-16 2:41 [RFC] Replace rebase with filtering Steven Grimm
2007-01-16 11:18 ` Johannes Schindelin
2007-01-16 19:20 ` Steven Grimm
2007-01-16 19:43 ` Steven Grimm [this message]
2007-01-16 20:35 ` Johannes Schindelin
2007-01-16 20:40 ` Steven Grimm
2007-01-16 21:14 ` Jakub Narebski
2007-01-16 21:22 ` Shawn O. Pearce
2007-01-16 21:23 ` Johannes Schindelin
2007-01-16 21:20 ` Johannes Schindelin
2007-01-16 21:49 ` Jakub Narebski
2007-01-16 22:31 ` Brian Gernhardt
2007-01-16 22:51 ` Johannes Schindelin
2007-01-16 22:53 ` Junio C Hamano
2007-01-16 22:57 ` Johannes Schindelin
2007-01-17 22:21 ` Steven Grimm
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=45AD2AE7.2010908@midwinter.com \
--to=koreth@midwinter.com \
--cc=Johannes.Schindelin@gmx.de \
--cc=git@vger.kernel.org \
/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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.