From: "Avery Pennarun" <apenwarr@gmail.com>
To: "Charles Bailey" <charles@hashpling.org>
Cc: "Junio C Hamano" <gitster@pobox.com>,
"Paul Gardiner" <osronline@glidos.net>,
git@vger.kernel.org
Subject: Re: How to find where a branch was taken from.
Date: Fri, 21 Mar 2008 14:48:28 -0400 [thread overview]
Message-ID: <32541b130803211148r651d03eev98a478b13e69f710@mail.gmail.com> (raw)
In-Reply-To: <20080321183225.GA13583@hashpling.org>
On Fri, Mar 21, 2008 at 2:32 PM, Charles Bailey <charles@hashpling.org> wrote:
> > In order to do this, however, I'm forced to remember where I got my
> > "original" version from, which isn't even that important. As the
> > developer of a particular patch, all I *really* should have to know
> > is: a) here are the things I added since I made my topic branch, and
> > b) here is the branch I want to rebase them onto so I can submit my
> > cleaned patches upstream.
>
> Why are you forced to remember?
>
> If you don't want to transplant the patches onto where the remote
> branch is now, then you just need to pick a commit on your current
> branch that is before any commit that you want to reorder/recombine
> and do a git rebase -i <sha1>. (It should be easy to pick a commit
> from git log. Perhaps it's the first one with and author that isn't
> you. [...]
All these things work, but they're unnecessarily tedious manual
remembering. If I have a lot of topic branches on the go at once,
things start getting a little messy and it's hard to remember which
patches came from where, particularly if I'm aggregating, reviewing,
and cleaning up patches from several people at work before sending
them upstream (in which case I don't always recognize the checkin
messages presented in git-rebase -i).
svn has "svn log --stop-on-copy", which is useful in exactly this
situation. A git branch is not really a "copy", of course, so the
actual implementation can't be the same.
"git show-branch" has logic very close to what we need here: if you
give it the names of your current branch and its parent, it'll show
you just the changes on both branches since the branchpoint. But I
don't really want to know about additional changes on the parent, only
on the branch I'm working with, and I often prefer the output to be in
git-log's (very flexible) format instead of git-show-branch.
Have fun,
Avery
next prev parent reply other threads:[~2008-03-21 18:49 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-03-21 9:05 How to find where a branch was taken from Paul Gardiner
2008-03-21 9:13 ` Junio C Hamano
2008-03-21 9:15 ` Junio C Hamano
2008-03-21 17:39 ` Avery Pennarun
2008-03-21 18:32 ` Charles Bailey
2008-03-21 18:48 ` Avery Pennarun [this message]
2008-03-21 20:03 ` Dmitry Potapov
2008-03-21 20:22 ` Daniel Barkalow
2008-03-21 20:25 ` J. Bruce Fields
2008-03-22 12:12 ` Paul Gardiner
2008-03-22 16:41 ` Jeff King
2008-03-22 16:54 ` Paul Gardiner
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=32541b130803211148r651d03eev98a478b13e69f710@mail.gmail.com \
--to=apenwarr@gmail.com \
--cc=charles@hashpling.org \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=osronline@glidos.net \
/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).