Re: [PATCH 4/4] describe/name-rev: tell name-rev to peel the incoming object to commit first
- From
Ramkumar Ramachandra <artagnon@gmail.com>
- Date
- Jul 8, 2013, 13:08 UTC
- Message-ID
- <CALkWK0nMmQO=cML-s9rgku+_4fZnYwtGC+daYPOBPn6-RFZj=g@mail.gmail.com>
- In-Reply-To
- <1373236424-25617-5-git-send-email-gitster@pobox.com>
Junio C Hamano wrote:
Show 15 quoted lines
> With this on top of the other patches in this series, you would get: > > $ git describe --contains $(git rev-parse v1.8.3 v1.8.3^0) > v1.8.3 > v1.8.3 > > while you can still differentiate tags and the commits they point at > with: > > $ git name-rev --refs=tags/\* --name-only $(git rev-parse v1.8.3 v1.8.3^0) > v1.8.3 > v1.8.3^0 > > The difference in these two behaviours is achieved by adding --peel-to-commit > option to "name-rev" and using it when "describe" internally calls it.
Essentially a revert of [2/4] for describe-purposes, achieved by adding an ugly command-line option to name-rev. Before we argue any further, let me ask: who uses name-rev (and depends strongly on its output)?! Our very own testsuite does not exercise it. There are exactly two users of describe/name-rev:
1. prompt, obviously. 2. DAG-tests, for simplification.
I really can't imagine it being useful elsewhere.