Subject: Re: [PATCH] describe: make '--always' fallback work after '--exact-match' failed

From: Junio C Hamano <[email-masked]>
Date: Thu, 20 Aug 2015 11:39:27 -0700

SZEDER Gábor <[email-masked]> writes:

> 'git describe [...] --always' should always show the unique abbreviated
> object name as a fallback when the given commit cannot be described with
> the given set of options, see da2478dbb0 (describe --always: fall back
> to showing an abbreviated object name, 2008-03-02).
>
> However, this is not the case when the combination '--exact-match
> --always' is given and the commit cannot be described, because in such
> cases 'git describe' errors out, as if '--always' were not given at all.
>
> Respect '--always' and print the unique abbreviated object name instead
> of erroring out when the commit cannot be described with '--exact-match
> --always'.
>
> Signed-off-by: SZEDER Gábor <[email-masked]>

Well, that can be argued both ways.  Your patch introduces a
regression, as "--exact-match" is an instruction to error out when
no tag exactly matches, and you deliberately break that.

My knee-jerk reaction is that the most sensible way forward is to
make --exact-match and --always mutually incompatible.