DPKG::Parse::Packages3pm
Parse the packages file
Usage
use DPKG::Parse::Packages;my $packages = DPKG::Parse::Packages->new('filename' => '/usr/src/packages/Packages',);while (my $entry = $packages->next_package) {print $entry->package . " " . $entry->version . "\n";}my $postfix = $packages->get_package('name' => 'postfix');
Overview
DPKG::Parse::Packages parses a dpkg/apt style Packages file and turns each entry into a DPKG::Parse::Entry object.
See DPKG::Parse for more information on the get_package and next_package methods.
See DPKG::Parse::Entry for more information on the entry objects.
Methods
- new('filename' => '/usr/src/packages/Packages')
-
Creates a new DPKG::Parse::Packages object. By default, it tries to open /usr/src/packages/Packages.
Releases
5 releases since Debian 9 (Stretch); the text changed 2 times.