Re: meaning of "Automatic date update in version.in" commits

Philippe Waroquiers
2017-09-20T19:56:11Z

On Wed, 2017-09-20 at 15:26 -0400, Mikhail Terekhov wrote:
> > Feel free to limit the bumps to exactly one after another commit.
> >
>
> What if build scripts obtain date of last commit automatically i.e.Â
> something like this:
>
> Â Â Â Â  ~/tmp/gdb/binutils-gdb (master)>git log -1 --format=%cdÂ
> --date=format:%Y%m%d
> Â Â Â Â  20170920
>
> Then there is no need for additional commit.
This is what valgrind build does, so as to produce:
$ valgrind --version
valgrind-3.14.0.GIT
$ valgrind --version -v
valgrind-3.14.0.GIT-f1ff8597ef-20170919

The final "official" 3.14.0 release will (should) not have the
.GIT part (but will keep the short sha1 and date in -v output).

The date of last commit was recently added in the --version -v output.
There is also a trailing X added to the date if there are some diffs
between workdir and index, or index and HEAD.

See auxprogs/make_or_upd_vgversion_h and Makefile.am in valgrind
sources for details.

Philippe