From eb415462afa2a8e6caaecd89eb2329d28cc4a9b0 Mon Sep 17 00:00:00 2001 From: Thierry Vignaud Date: Thu, 13 Dec 2012 09:54:17 +0000 Subject: (add_distrib_media) associate media_cfg data to media when adding them needed for drakx installer complement commit r259200 by cfergeau on Aug 13 2009: "Save media.cfg files locally to map urpmi.cfg media to media.cfg" which only associate media_cfg data to media loaded from config, not those just added --- NEWS | 3 +++ urpm/media.pm | 6 ++++++ 2 files changed, 9 insertions(+) diff --git a/NEWS b/NEWS index 376c7b11..6c98010a 100644 --- a/NEWS +++ b/NEWS @@ -1,3 +1,6 @@ +- library: + o associate media_cfg data to media when adding them + Version 7.13 - 4 December 2012, by Thierry Vignaud - library speedups when looking up packages: diff --git a/urpm/media.pm b/urpm/media.pm index 92f4a777..97228f76 100644 --- a/urpm/media.pm +++ b/urpm/media.pm @@ -1055,6 +1055,12 @@ sub add_distrib_media { ); ++$medium_index; } + + # associate newly added medias with their description in a media.cfg file + # @media content will be modified and then add_existing medium will take + # care of copying the media to $urpm + _associate_media_with_mediacfg($urpm, [ map { name2medium($urpm, $_) } @newnames ]); + return @newnames; } -- cgit v1.2.1