summaryrefslogtreecommitdiffstats
path: root/lib/App/ArchLinux/PackagerTools.pm
diff options
context:
space:
mode:
authorFlorian Pritz <bluewind@xinu.at>2018-11-19 00:57:11 +0100
committerFlorian Pritz <bluewind@xinu.at>2018-11-19 00:57:11 +0100
commitdf8f04661d46f03f7c2dd4041c520c479179ed8a (patch)
tree10c42c6537cc0ec46877412e1997b91ff04a94bb /lib/App/ArchLinux/PackagerTools.pm
parenta01c7719bc535092ce3a6e83bb26159d3f117d72 (diff)
downloadApp-ArchLinux-PackagerTools-df8f04661d46f03f7c2dd4041c520c479179ed8a.tar.gz
App-ArchLinux-PackagerTools-df8f04661d46f03f7c2dd4041c520c479179ed8a.tar.xz
Batch calls to expac for performance
Signed-off-by: Florian Pritz <bluewind@xinu.at>
Diffstat (limited to 'lib/App/ArchLinux/PackagerTools.pm')
-rw-r--r--lib/App/ArchLinux/PackagerTools.pm4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/App/ArchLinux/PackagerTools.pm b/lib/App/ArchLinux/PackagerTools.pm
index 0a45bb8..cfc2f01 100644
--- a/lib/App/ArchLinux/PackagerTools.pm
+++ b/lib/App/ArchLinux/PackagerTools.pm
@@ -80,8 +80,10 @@ older) and the CPAN distribution.
method get_updateable_packages($distribution_names) {
my @packages;
+ my $repo_versions = $self->{deps}->{pacman}->get_perl_distribution_versions($distribution_names);
for my $dist_name ($distribution_names->@*) {
- my $repo_version = $self->{deps}->{pacman}->get_perl_distribution_version($dist_name);
+ #my $repo_version = $self->{deps}->{pacman}->get_perl_distribution_version($dist_name);
+ my $repo_version = $repo_versions->{$dist_name};
my $dist = $self->{deps}->{cpan}->get_dist($dist_name);
if ($self->{deps}->{cpan}->is_newer_version_available($dist_name, $repo_version)) {
$log->infof('New version available for dist \'%s\': %s', $dist_name, $dist->{version});