Re: Package description stats
On Mon, Aug 21, 2006 at 03:56:13PM +0200, Martijn van Oosterhout wrote:
> On 8/21/06, Jens Seidel <jensseidel@users.sf.net> wrote:
> >Do you know how the DDTS priorities are determined? Using popcon?
> >It would be nice to document this.
>
> I suspect it using the priorities, but not updating them. The packages
> out of order look like packages that used to be standard, but since
> have become required, or vice-versa.
no, it don't use popcon.
> But without seeing the source code it's just guess work. Only the
> owner of the DDTS can tell us...
some code snips:
...
if (/^Package: (.*)/) { # new item
$package=$1;
$source=$1;
$prioritize=40;
$prioritize -= 1 if $package =~ /^kernel/i;
$prioritize -= 1 if $package =~ /^kernel-source/i;
$prioritize -= 2 if $package =~ /^kernel-patch/i;
$prioritize -= 3 if $package =~ /^kernel-header/i;
$prioritize += 3 if $package =~ /^kernel-image/i;
$prioritize -= 2 if $package =~ /^lib/i;
$prioritize -= 1 if $package =~ /-doc$/i;
$prioritize -= 6 if $package =~ /-dev$/i;
}
...
if (/^Priority: (.*)/) { # new item
$priority=$1;
if ($priority =~ /extra/i ) {
$prioritize+=0;
} elsif ($priority =~ /optional/i ) {
$prioritize+=5;
} elsif ($priority =~ /standard/i ) {
$prioritize+=10;
} elsif ($priority =~ /important/i ) {
$prioritize+=15;
} elsif ($priority =~ /required/i ) {
$prioritize+=20;
}
}
...
if (/^Section: (.*)/) { # new item
$section="$1";
if ($section =~ /devel/i ) {
$prioritize-=3;
} elsif ($section =~ /net/i ) {
$prioritize-=2;
} elsif ($section =~ /oldlibs/i ) {
$prioritize-=3;
} elsif ($section =~ /libs/i ) {
$prioritize-=2;
}
}
...
Gruss
Grisu
--
Michael Bramer - http://www.feuerwehr.kreuzau.de/wiki/
PGP: finger grisu@db.debian.org -- Linux Sysadmin -- Use Debian Linux
Free Software is like sex: You don't know what's it like until you've
tried it.
Reply to: