Re: [PATCH 4/4] describe/name-rev: tell name-rev to peel the incoming object to commit first

2013-07-09 Thread Junio C Hamano
Jeff King p...@peff.net writes: Although I am still not clear on why it would not be up to the caller of git-describe in the first place to decide which they wanted. Thanks for a dose of sanity. Even though the part of the miniseries that makes sure that X (Y) output from name-rev always

Re: [PATCH 4/4] describe/name-rev: tell name-rev to peel the incoming object to commit first

2013-07-09 Thread Ramkumar Ramachandra
Junio C Hamano wrote: $ git describe $(git rev-parse v1.8.3) v1.8.3 $ git describe --contains $(git rev-parse v1.8.3) v1.8.3^0 This is a correct observation, and I've already submitted the correct fix: name-rev: strip trailing ^0 in when --name-only. $ git describe

Re: [PATCH 4/4] describe/name-rev: tell name-rev to peel the incoming object to commit first

2013-07-08 Thread Ramkumar Ramachandra
Junio C Hamano wrote: 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/\*

Re: [PATCH 4/4] describe/name-rev: tell name-rev to peel the incoming object to commit first

2013-07-08 Thread Jeff King
On Sun, Jul 07, 2013 at 03:33:44PM -0700, Junio C Hamano wrote: 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

Re: [PATCH 4/4] describe/name-rev: tell name-rev to peel the incoming object to commit first

2013-07-08 Thread Jeff King
On Mon, Jul 08, 2013 at 06:38:32PM +0530, Ramkumar Ramachandra wrote: Junio C Hamano wrote: 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

Re: [PATCH 4/4] describe/name-rev: tell name-rev to peel the incoming object to commit first

2013-07-08 Thread Junio C Hamano
Jeff King p...@peff.net writes: 1. Behave more or less the same between git name-rev $sha1 and echo $sha1 | git name-rev --stdin. Your patch improves that. Though I note that --peel-to-commit does not affect --stdin at all. Should it? And of course the two differ in that the

Re: [PATCH 4/4] describe/name-rev: tell name-rev to peel the incoming object to commit first

2013-07-08 Thread Jeff King
On Mon, Jul 08, 2013 at 10:33:26PM -0700, Junio C Hamano wrote: Jeff King p...@peff.net writes: 1. Behave more or less the same between git name-rev $sha1 and echo $sha1 | git name-rev --stdin. Your patch improves that. Though I note that --peel-to-commit does not affect

[PATCH 4/4] describe/name-rev: tell name-rev to peel the incoming object to commit first

2013-07-07 Thread Junio C Hamano
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