From 4388f345f41d5f74c70b23e99e3751e76666cb62 Mon Sep 17 00:00:00 2001 From: Guillaume Cottenceau Date: Thu, 5 Feb 2004 14:31:37 +0000 Subject: explain what's going on, when we install from a file, so that one-click adding people will get that explanation --- gurpmi.addmedia | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'gurpmi.addmedia') 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)) { -- cgit v1.2.1