Git development
 help / color / mirror / Atom feed
From: Todd Zullinger <tmz@pobox.com>
To: Marcus Comstedt <marcus@mc.pp.se>
Cc: git@vger.kernel.org
Subject: Re: Bug report: %h for abbreviated hashes broken after 1.7.1
Date: Wed, 25 Aug 2010 13:27:19 -0400	[thread overview]
Message-ID: <20100825172718.GC4925@inocybe.localdomain> (raw)
In-Reply-To: <loom.20100825T095907-907@post.gmane.org>

[-- Attachment #1: Type: text/plain, Size: 1819 bytes --]

Marcus Comstedt wrote:
> Todd A. Jacobs <tjacobs <at> si2services.com> writes:
>
>> Fair enough. Thank you for taking the time to explain further. I guess
>> I still don't understand how both the patch and the tag are both on
>> the master branch:
>>
>>     $ git branch --contains v1.7.2.2
>>     * master
>>
>>     $ git branch --contains 35039ce
>>     * master
>
> The commit tagged with v1.7.2.2 is on the master branch because
> it was merged there.  The tag was not cut from the master branch
> but from the maint branch.  You are fooled by git branch here because
> you display only your local branches, and you don't have a local
> maint branch.  Add -r to the command, and you will see the commits
> are in multiple branches at origin.
>
> I'm afraid the git command line tools are rather unhelpful in these
> cases (it's hard to find the answer if you don't already know it),
> but gitk allows you to see it quite nicely.  Run "gitk origin/master",
> and search for 35039ce.  You'll see the commit being made on a topic
> branch, which is merged into master (the leftmost track) on 2010-08-18.
> You can also clearly see v1.7.2.2 being cut from maint (the track
> immediately to the right of master) on 2010-08-20, shortly after which
> maint is merged into master (c11969), which is why master "contains"
> 8c67c3, which is what you're really looking for when you say
> "--contains v1.7.2.2".

In cases like this I find tag --contains handy:

    $ git tag --contains 35039ce

Returns nothing, as no tag has 35039ce.

-- 
Todd        OpenPGP -> KeyID: 0xBEAF0CE3 | URL: www.pobox.com/~tmz/pgp
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
A word to the wise ain't necessary -- it's the stupid ones who need
the advice.
    -- Bill Cosby


[-- Attachment #2: Type: application/pgp-signature, Size: 542 bytes --]

      reply	other threads:[~2010-08-25 17:27 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-08-25  2:54 Bug report: %h for abbreviated hashes broken after 1.7.1 Todd A. Jacobs
2010-08-25  4:14 ` Jonathan Nieder
2010-08-25  5:07   ` Todd A. Jacobs
2010-08-25  6:16     ` Björn Steinbrink
2010-08-25  6:24     ` Jonathan Nieder
2010-08-25  7:20       ` Todd A. Jacobs
2010-08-25  8:08         ` Marcus Comstedt
2010-08-25 17:27           ` Todd Zullinger [this message]

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=20100825172718.GC4925@inocybe.localdomain \
    --to=tmz@pobox.com \
    --cc=git@vger.kernel.org \
    --cc=marcus@mc.pp.se \
    /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