Re: Doubts in Sigar packaging
On Wed, 15 Sep 2010 15:18:20 +0200
Adam Borowski <email@example.com> wrote:
> On Wed, Sep 15, 2010 at 01:31:39PM +0100, Tony Houghton wrote:
> > Matthew Palmer <firstname.lastname@example.org> wrote:
> > > > sigar-1.7.0~git833ca18ecfc1f3f45eaf8544d8cdafef6603772d
> > > Yeah, that isn't going to work -- what if the next SHA you want to
> > > package is 12345[blah]... it'll look like a lesser version to dpkg.
> > I had a similar problem when I moved roxterm to git . I only use
> > git-derived versions for testing between releases but it's still useful.
> > Here's a bit of script that can help:
> > Date=`git log --date=iso | grep -m1 '^Date:' | sed 's/^Date:\s*//'`
> > Rev=`date -d "$Date" -u +'%Y%m%d%H%M%S'`
> Why won't you just use `git --describe`?
> It produces nice version numbers of the format
> <last tag>-<number of commits after it>-<start of hash>
> (or just <last tag> when you're packaging a release)
Thanks, that looks useful.
> Depending on your upstream's versioning scheme you may want to stick a
> tilde somewhere. For example, if the upstream tagged a branch that is
> to-be 0.8 as "0.8.0-a0", you'd want to make that "0.8.0~a0". This way,
> "0.8.0-a0-1247-gf38ef2b" will become "0.8.0~a0-1247-gf38ef2b" and final
> "0.8" -- just "0.8.0".
Don't upstream version numbers have to be without hyphens so that Debian
can easily distinguish the Debian revision from the upstream? Or is it
OK, because it takes anything after the last hyphen to be the Debian
To make it absolutely clear that the release is newer than any
pre-release snapshots I reserve *.0 version numbers for pre-release
snapshots and use *.1 for release, so in your example I'd have 0.8.0*
for snapshots and then 0.8.1 for release. Then I would use 0.8.1-* until
releasing 0.8.2, then 0.9.0* for testing a major new feature to be
released in 0.9.1.
TH * http://www.realh.co.uk