aboutsummaryrefslogtreecommitdiffstats
path: root/Rpmdrake
diff options
context:
space:
mode:
authorThierry Vignaud <tv@mandriva.org>2008-02-12 09:40:39 +0000
committerThierry Vignaud <tv@mandriva.org>2008-02-12 09:40:39 +0000
commit6ba17da2ed0430eea39cab733daf3403e613bf08 (patch)
tree131214f5fbc39e26b0d66435bdb857ab4fb46903 /Rpmdrake
parentb5b33d79d83c212d2f5c83635f1c079c51c3879d (diff)
downloadrpmdrake-6ba17da2ed0430eea39cab733daf3403e613bf08.tar
rpmdrake-6ba17da2ed0430eea39cab733daf3403e613bf08.tar.gz
rpmdrake-6ba17da2ed0430eea39cab733daf3403e613bf08.tar.bz2
rpmdrake-6ba17da2ed0430eea39cab733daf3403e613bf08.tar.xz
rpmdrake-6ba17da2ed0430eea39cab733daf3403e613bf08.zip
add list of programs with GUI view (#36486)
Diffstat (limited to 'Rpmdrake')
-rw-r--r--Rpmdrake/gui.pm1
-rw-r--r--Rpmdrake/pkg.pm3
2 files changed, 4 insertions, 0 deletions
diff --git a/Rpmdrake/gui.pm b/Rpmdrake/gui.pm
index 22918fbb..fb712039 100644
--- a/Rpmdrake/gui.pm
+++ b/Rpmdrake/gui.pm
@@ -469,6 +469,7 @@ sub pkgs_provider {
},
backports => sub { @filtered_pkgs = @{$h->{backports}} },
meta_pkgs => sub { @filtered_pkgs = @{$h->{meta_pkgs}} },
+ gui_pkgs => sub { @filtered_pkgs = @{$h->{gui_pkgs}} },
);
foreach my $importance (qw(bugfix security normal)) {
$filter_methods{$importance} = sub {
diff --git a/Rpmdrake/pkg.pm b/Rpmdrake/pkg.pm
index 7860b6f8..791eb872 100644
--- a/Rpmdrake/pkg.pm
+++ b/Rpmdrake/pkg.pm
@@ -476,6 +476,8 @@ sub get_pkgs {
# urpmi only care about the first medium where it found the package,
# so there's no need to list the same package several time:
@installable_pkgs = uniq(difference2(\@installable_pkgs, \@updates));
+
+ my @gui_pkgs = map { chomp; $_ } cat_('/usr/share/rpmdrake/gui.lst');
+{ urpm => $urpm,
all_pkgs => \%all_pkgs,
@@ -483,6 +485,7 @@ sub get_pkgs {
installable => \@installable_pkgs,
updates => \@updates,
meta_pkgs => [ grep { /^task-/ } keys %all_pkgs ],
+ gui_pkgs => [ grep { member(($all_pkgs{$_}{pkg}->fullname)[0], @gui_pkgs) } keys %all_pkgs ],
update_descr => $update_descr,
backports => \@backports,
};