Mercurial 0.6b package for Ubuntu

Kevin Smith yarcs at
Tue Aug 2 07:06:32 CDT 2005

Vincent Danjean wrote:
> On Fri, Jul 29, 2005 at 09:36:36AM -0400, Kevin Smith wrote:
>>If you installed the Ubuntu 0.6 package earlier, you will need to force 
>>a "downgrade" to 0.6b, due to Debian package system naming rule 
>>oddities. Wes and I have changed the revision naming a bit, so hopefully 
>>this won't be a problem with any future updates.
> Is this due to your version of dpkg ? 

Nope. It's due to the Debian rules across all versions of dpkg.

Our original package was mercurial-0.6-hoary1-1, which was parsed by the 
Debian tools as:

Package: mercurial
Version: 0.6-hoary1
Revision: 1

When 0.6b came out, we tried to have mercurial-0.6b-hoary1-1, which was 
parsed as:

Package: mercurial
Version: 0.6b-hoary1
Revision: 1

Debian's version comparison rules state that letters sort *before* any 
other character, so "0.6-" > "0.6b". At a glance, it sounds silly, but I 
trust that it must be helpful in some way.

So we changed the new 0.6b package to mercurial-0.6b-1+hoary1, which is:

Package: mercurial
Version: 0.6b
Revision: 1+hoary1

We still have the problem that "0.6-hoary1" > "0.6b", which is why the 
downgrade is required. But in the future, if there is a 0.7 followed by 
a 0.7b, our new naming scheme will work as desired.

kevins at aria:~/work/apt-repo$ dpkg --compare-versions 0.6-hoary1-1 "<" 
0.6b-1+hoary1 && echo ok
kevins at aria:~/work/apt-repo$ dpkg --compare-versions 0.7-1+hoary1 "<" 
0.7b-1+hoary1 && echo ok
kevins at aria:~/work/apt-repo$


More information about the Mercurial mailing list