On Mon, Aug 20, 2012 at 07:03:58AM -0400, James McCoy wrote: > On Mon, Aug 20, 2012 at 09:39:34AM +0200, Andreas Tille wrote: > > On Mon, Aug 20, 2012 at 12:10:19AM +0200, gregor herrmann wrote: > > > Next guess: > > > > > > Dpkg::Control::Hash - parse and manipulate a block of RFC822-like fields > > > (libdpkg-perl) > > > > How would you compare this to Jonas solution using > > > > use Parse::DebControl; > > Using Dpkg::Control::Hash would be preferable since we're already using > that library in devscripts.
This would be an argument but if I do in the source of devscripts $ find . -type f -exec grep -H "Dpkg::Control" \{\} \; ./debian/changelog: + Parse dpkg's status file using Dpkg::Control. ./Devscripts/PackageDeps.pm:use Dpkg::Control; ./Devscripts/PackageDeps.pm: while (defined($ctrl = Dpkg::Control->new(type => CTRL_FILE_STATUS)) ./Devscripts/Packages.pm:use Dpkg::Control; ./Devscripts/Packages.pm: while (defined($ctrl = Dpkg::Control->new()) ./Devscripts/Packages.pm: while (defined($ctrl = Dpkg::Control->new(type => CTRL_FILE_STATUS)) ./scripts/debi.pl:use Dpkg::Control; ./scripts/debi.pl:my $ctrl = Dpkg::Control->new(name => $changes, type => CTRL_FILE_CHANGES); ./scripts/mk-build-deps.pl:use Dpkg::Control; ./scripts/mk-build-deps.pl: my $ctrl = Dpkg::Control->new(allow_pgp => 1, type => CTRL_UNKNOWN); $ find . -type f -exec grep -H "Parse::DebControl" \{\} \; ./scripts/debchange.pl: require Parse::DebControl; ./scripts/debchange.pl: $lpdc_broken="couldn't load Parse::DebControl: $@"; ./scripts/debchange.pl: my $parser = Parse::DebControl->new; ./scripts/debchange.pl: my $parser = new Parse::DebControl; both are used (admittedly the usage statistics Dpkg::Control vs Parse::DebControl is 4:1). May I asume that the intention of your remark was that you want to get rid of Parse::DebControl inside devscripts or was you just not aware of its usage. I'm totally unbiased because I did not used any of both - just want to make an educated choice. Kind regards Andreas. -- http://fam-tille.de -- To UNSUBSCRIBE, email to debian-devel-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org Archive: http://lists.debian.org/20120820112253.ge19...@an3as.eu