Bug#968000: libconfig-model-dpkg-perl: Get policy release dates in another way

Dominique Dumont dod at debian.org
Wed Sep 8 17:46:19 BST 2021


Hi

Re-reading the thread of this bug, there's still the solution based on debian-policy. Even though there's still no file that provide the policy version, this one can be extracted from debian-policy changelog with something like:

$ zcat /usr/share/doc/debian-policy/changelog.gz | head -1 | perl -n -E '/\((\d+\.\d+\.\d+)/; say $1;'
4.6.0

On the other hand, people might not like yet another dependency on cme. And it may be hard to explain a dependency on a pure doc package.

And this will break in debian-slim container images because docs are not installed... oh well... :-/

Back to gregoa's proposal...

On Wednesday, 8 September 2021 17:49:04 CEST gregor herrmann wrote:
> Implemented in git, but not uploaded because
> 
> - I'd appreciate review from dod

This regexp may be too strict:
$std_ver =~ s|^(\d+\.\d+\.\d+)\.\d+$|$1|;

I don't know if policy people are committed to used 4 digits version. 

It may be better to extract the first 3 digits and call it a day.
(i.e. $std_ver =~ s|^(\d+\.\d+\.\d+)|$1|; )

In any case, the program should croak if $std_ver is undef because the regexp does not match


> - and I discovered a wrinkle:

Which you fixed...

All the best



More information about the pkg-perl-maintainers mailing list