diff options
Diffstat (limited to 'gurpmi.addmedia')
-rwxr-xr-x | gurpmi.addmedia | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/gurpmi.addmedia b/gurpmi.addmedia index 14fa5518..5751008b 100755 --- a/gurpmi.addmedia +++ b/gurpmi.addmedia @@ -54,8 +54,10 @@ if ($@) { } $::isStandalone = 1; +my $fromfile; if (@ARGV == 1 && $ARGV[0] =~ /\.urpm-media$/) { @ARGV = split /\n/, cat_($ARGV[0]); + $fromfile = 1; } my $update = 0; @@ -70,6 +72,15 @@ if ($url !~ m,^(file://|ftp://|http://|removable://), || $with && !$with_hdlist) POSIX::_exit(-1); } +$fromfile and interactive_msg('gurpmi.addmedia', +N("%s + +Is it ok to continue?", +N("You are about to add a new packages medium, `%s'. +That means you will be able to add new software packages +to your system from that new medium.", $name)), + yesno => 1) or myexit(0); + my $urpm = urpm->new; $urpm->read_config; if (add_medium_and_check($urpm, { probe_with => !$with }, $name, $url, $with_hdlist, update => $update)) { |