summaryrefslogtreecommitdiffstats
path: root/urpmi
diff options
context:
space:
mode:
authorRafael Garcia-Suarez <rgarciasuarez@mandriva.org>2004-07-09 09:28:20 +0000
committerRafael Garcia-Suarez <rgarciasuarez@mandriva.org>2004-07-09 09:28:20 +0000
commitc3a3eb8f1326af1b43623d963359b8d115e1e8ab (patch)
tree4aea008e88127542cd049c656309f45da213d6aa /urpmi
parentd7f6060aba7df0b4e108aeb70bdc93685c2e2bb0 (diff)
downloadurpmi-c3a3eb8f1326af1b43623d963359b8d115e1e8ab.tar
urpmi-c3a3eb8f1326af1b43623d963359b8d115e1e8ab.tar.gz
urpmi-c3a3eb8f1326af1b43623d963359b8d115e1e8ab.tar.bz2
urpmi-c3a3eb8f1326af1b43623d963359b8d115e1e8ab.tar.xz
urpmi-c3a3eb8f1326af1b43623d963359b8d115e1e8ab.zip
More grammarworthy information messages (or, don't say "1 packages")
Diffstat (limited to 'urpmi')
-rwxr-xr-xurpmi8
1 files changed, 6 insertions, 2 deletions
diff --git a/urpmi b/urpmi
index 4dddb535..bea2338c 100755
--- a/urpmi
+++ b/urpmi
@@ -501,7 +501,9 @@ foreach my $pkg (sort { $a->name cmp $b->name } @{$urpm->{depslist}}[keys %{$sta
}
}
if ($env) {
- my $msg = N("To satisfy dependencies, the following %d packages are going to be installed (%d MB)", $#to_install+1, toMb($sum));
+ my $msg = $#to_install
+ ? N("To satisfy dependencies, the following %d packages are going to be installed (%d MB)", $#to_install+1, toMb($sum))
+ : N("To satisfy dependencies, the following package is going to be installed (%d MB)", toMb($sum));
my $p = join "\n", @to_install;
print STDERR "$msg:\n$p\n";
exit 0; #- exit now for specific environment.
@@ -510,7 +512,9 @@ if (@root_only) {
print STDERR N("You need to be root to install the following dependencies:\n%s\n", join ' ', @root_only);
exit 1;
} elsif (!$urpm->{options}{auto} && ($ask_user || $urpm::args::options{X}) && @to_install) {
- my $msg = N("To satisfy dependencies, the following %d packages are going to be installed (%d MB)", $#to_install+1, toMb($sum));
+ my $msg = $#to_install
+ ? N("To satisfy dependencies, the following %d packages are going to be installed (%d MB)", $#to_install+1, toMb($sum))
+ : N("To satisfy dependencies, the following package is going to be installed (%d MB)", toMb($sum));
my $msg2 = N("Is this OK?");
my $p = join "\n", @to_install;
if ($urpm::args::options{X}) {