[Dnsmasq-discuss] Snapshot archives downloaded from gitweb are not versioned properly
Geert Stappers
stappers at stappers.nl
Mon Sep 12 10:47:05 UTC 2022
On Mon, Sep 12, 2022 at 04:51:26PM +0800, Johnny S. Lee via Dnsmasq-discuss wrote:
> On Mon, 12 Sept 2022 at 15:22, <imnozi at gmail.com> wrote:
> > On Mon, 12 Sep 2022 08:26:14 +0200 Geert Stappers via Dnsmasq-discuss wrote:
> > > On Mon, Sep 12, 2022 at 11:51:22AM +0800, Johnny S. Lee via Dnsmasq-discuss wrote:
> > > > The contents of file VERSION from the tar.gz files of the latest 3 commits:
> > > >
> > > > dnsmasq-c4b9bc6/VERSION: (HEAD -> master)
> > > > dnsmasq-4447d48/VERSION: (tag: v2.87rc1, origin/master, origin/HEAD)
> > > > dnsmasq-04cc2ae/VERSION:
> > >
> > > I do read "there is something wrong", but I don't get what.
> > > Hopefully do others understand it. If not, elaborate the inconvenience.
> >
> > *I* might expect the displayed version info to contain reasonably
> > consistent information. How often is the VERSION file changed?
>
> It changes from "(HEAD -> master)" to blank when there is a new commit.
> Checksum of the archive of the same commit probably changes too.
>
> > Is the VERSION file meaningful only at the time of a release and can
> > change 'drastically' between releases? Or should it contain data like
> > "tag: v2.87rc1, origin/master, origin/HEAD" through the life of rc1
> > (for example)?
> >
> It's meaningful when the source directory is not a git repo.
> When building from a git repo, `git describe` is run for getting the version.
> I would expect snapshot archives to have the same.
The inconvenience in my words:
* gitweb .tgz snapshots are being downloaded (for some untold reason)
* inside the snapshot is file VERSION
* content of that VERSION file doesn't meet expectations
* however content of the .tgz VERSION differs from content in git VERSION
<screenshot>
$ git log --patch VERSION
commit 07736e8dcb7a8d776cd7d25b32d8e413fa3764f3
Author: Simon Kelley <simon at thekelleys.org.uk>
Date: Thu Jan 5 22:00:08 2012 +0000
VERSION file
diff --git a/VERSION b/VERSION
new file mode 100644
index 0000000..998eb1f
--- /dev/null
+++ b/VERSION
@@ -0,0 +1 @@
+$Format:%d$
$
</screenshot>
So VERSION in `git` didn't change in ten years.
On Mon, Sep 12, 2022 at 03:14:52PM +0800, Johnny S. Lee via Dnsmasq-discuss wrote:
> On Mon, 12 Sept 2022 at 14:26, Geert Stappers wrote:
> > On Mon, Sep 12, 2022 at 11:51:22AM +0800, Johnny S. Lee via Dnsmasq-discuss wrote:
> > > ...
> > > Would it be better adding "%(describe)" to the format in file VERSION?
> >
> > I do read that as "I might have a solution for it".
> > I tried to understand it and my attempt did bring:
> >
> > --- a/VERSION
> > +++ b/VERSION
> > @@ -1 +1 @@
> > -$Format:%d$
> > +$Format:%d %(describe)$
> >
> > Is that what you are trying to say?
>
> Right, something like that.
Those who have apetite for it: Please provide patches.
> bld/get-version should also be updated though.
Acknowledge.
Groeten
Geert Stappers
--
Silence is hard to parse
More information about the Dnsmasq-discuss
mailing list