aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThierry Vignaud <tv@mandriva.org>2008-10-11 11:31:48 +0000
committerThierry Vignaud <tv@mandriva.org>2008-10-11 11:31:48 +0000
commit6a579c9915d86b338cc3b5fb9bd068788b535064 (patch)
treefa54fd3e79ea7a131b4bcd9146a19290cb425b87
parente4d8c20f4be6a0c3072ddaba009d6e78372e2613 (diff)
downloadrpmdrake-6a579c9915d86b338cc3b5fb9bd068788b535064.tar
rpmdrake-6a579c9915d86b338cc3b5fb9bd068788b535064.tar.gz
rpmdrake-6a579c9915d86b338cc3b5fb9bd068788b535064.tar.bz2
rpmdrake-6a579c9915d86b338cc3b5fb9bd068788b535064.tar.xz
rpmdrake-6a579c9915d86b338cc3b5fb9bd068788b535064.zip
(fast_open_urpmi_db) do not read big debug media if 'ignore_debug_media'
option is set
-rw-r--r--NEWS1
-rw-r--r--Rpmdrake/open_db.pm4
-rw-r--r--rpmdrake.pm4
3 files changed, 8 insertions, 1 deletions
diff --git a/NEWS b/NEWS
index 53d17b94..a09ff856 100644
--- a/NEWS
+++ b/NEWS
@@ -1,3 +1,4 @@
+- do not read big debug media if 'ignore_debug_media' option is set
- try harder not to have gray wait message dialogs
(needs drakxtools > 11.67)
- when using --env:
diff --git a/Rpmdrake/open_db.pm b/Rpmdrake/open_db.pm
index d7b3de40..d3cf568d 100644
--- a/Rpmdrake/open_db.pm
+++ b/Rpmdrake/open_db.pm
@@ -91,6 +91,10 @@ sub fast_open_urpmi_db() {
};
urpm::media::read_config($urpm);
+ foreach (@{$urpm->{media}}) {
+ next if $_->{ignore};
+ urpm::media::_tempignore($_, 1) if $ignore_debug_media->[0] && $_->{name} =~ /debug/i;
+ }
# FIXME: seems uneeded with newer urpmi:
if ($error_happened) {
touch('/etc/urpmi/urpmi.cfg');
diff --git a/rpmdrake.pm b/rpmdrake.pm
index aa35c6d1..8b42e273 100644
--- a/rpmdrake.pm
+++ b/rpmdrake.pm
@@ -48,6 +48,7 @@ our @EXPORT = qw(
$changelog_first_config
$filter
$dont_show_selections
+ $ignore_debug_media
$mandrakeupdate_wanted_categories
$mandrivaupdate_height
$mandrivaupdate_width
@@ -156,7 +157,7 @@ $ENV{HOME} = $::env if $::env = $Rpmdrake::init::rpmdrake_options{env}[0];
our $configfile = "$ENV{HOME}/.rpmdrake";
our ($changelog_first_config, $filter, $max_info_in_descr, $mode, $tree_flat, $tree_mode);
-our ($mandrakeupdate_wanted_categories, $offered_to_add_sources, $no_confirmation);
+our ($mandrakeupdate_wanted_categories, $ignore_debug_media, $offered_to_add_sources, $no_confirmation);
our ($rpmdrake_height, $rpmdrake_width, $mandrivaupdate_height, $mandrivaupdate_width);
our %config = (
mandrakeupdate_wanted_categories => { var => \$mandrakeupdate_wanted_categories, default => [ qw(security) ] },
@@ -164,6 +165,7 @@ our %config = (
mandrivaupdate_width => { var => \$mandrivaupdate_width, default => [ 0 ] },
mandrivaupdate_height => { var => \$mandrivaupdate_height, default => [ 0 ] },
max_info_in_descr => { var => \$max_info_in_descr, default => [] },
+ ignore_debug_media => { var => \$ignore_debug_media, default => [ 0 ] },
offered_to_add_sources => { var => \$offered_to_add_sources, default => [ 0 ] },
tree_mode => { var => \$tree_mode, default => [ qw(gui_pkgs) ] },
tree_flat => { var => \$tree_flat, default => [ 0 ] },