Le 17/11/2018 à 22:20, Mattia Rizzolo a écrit :
> On Sat, Nov 17, 2018 at 01:19:38PM -0500, Alexandre Viau wrote:
>> For example, if a repository has a v0.3.0 tag and commits were done
>> after the tag, the last commit being done on 2018-10-25 and having the
>> hash f80706d, the version should be:
>> - 0.3.0~git20181025.f80706d
>>
>> However, uscan currently reports the following version:
>> - 0.0~git20181025.f80706d
>>
>> My watch file is like so:
>> ```
>> version=4
>> opts=mode=git, \
>> https://github.com/collectd/go-collectd.git \
>> HEAD
>> ```
>>
>> The specs for the git mode were originally discussed in #811565. It
>> might be that this part of the spec was simply not implemented yet, so
>> feel free to change the severity to wishlist.
>
> Even if they were discussed there, changing such detail would be a
> breaking change now, so I think it would be hard to do "by default".
>
> I think what you are saying is that git HEAD tracking always uses
> 0.0~ instead of using a version like the one used by `git describe`?
Yes, until now "pretty" option is given directly to `git log
--pretty=format:$pretty` which has no option to get last tag.
> In that case, skimming through #811565 it seems to me that it was
> purposefully left out, so at most adding it now it could/should be done
> with an option.
Done with a macro to allow DD to customize their "pretty"