Parse::Fedora::Packages - Parse Fedora package information
use Parse::Fedora::Packages; my $p = Parse::Fedora::Packages->new; $p->parse_primary("primary.xml"); my @all = $p->list_packages(); print $all[0]->{name}; print $all[0]->{version}; print $all[0]->{summary}; print $all[0]->{description}; print $all[0]->{url};
Constructor
my $p = Parse::Fedora::Packages->new
Given a primary.xml file it will read it into memory and parse it.
Returns nothing.
Throws exception if the file is invalid xml.
$p->parse_primary("primary.xml");
Given a primary.xml.gz file it will read it into memory and parse it. If a URL is passed as argument, it will download it.
$p->parse_primary_gz('primary.xml'); # Or $p->parse_primary_gz('http://mirror.yandex.ru/fedora/tigro/non-free/11/i386/repodata/primary.xml.gz');
returns list of packages (sub xml)
returns number of packages
This is an alpha relese, The API will change.
Provide parse_primary_gz("primary.xml.gz");
Gabor Szabo, <gabor@pti.co.il>
Currently maintained by rarbox, <rarbox@cpan.org>
Copyright (C) 2007-2008 Gabor Szabo <gabor@pti.co.il>. All Rights Reserverd.
This module is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
Parse::Debian::Packages, Module::Packaged, Module::Packaged::Report
To install Parse::Fedora::Packages, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Parse::Fedora::Packages
CPAN shell
perl -MCPAN -e shell install Parse::Fedora::Packages
For more information on module installation, please visit the detailed CPAN module installation guide.