summaryrefslogtreecommitdiffstats
path: root/urpmi.update
diff options
context:
space:
mode:
authorFrancois Pons <fpons@mandriva.com>2001-02-16 13:01:02 +0000
committerFrancois Pons <fpons@mandriva.com>2001-02-16 13:01:02 +0000
commita73a3e74e32ec5360b62c68f8a80b55a4b79bfdd (patch)
tree0865be280c28fac5d5c0c4df70030cd06cba5a00 /urpmi.update
parentec45c9cfff35dd390422a2b0ea40dc60cf9f2bc0 (diff)
downloadurpmi-a73a3e74e32ec5360b62c68f8a80b55a4b79bfdd.tar
urpmi-a73a3e74e32ec5360b62c68f8a80b55a4b79bfdd.tar.gz
urpmi-a73a3e74e32ec5360b62c68f8a80b55a4b79bfdd.tar.bz2
urpmi-a73a3e74e32ec5360b62c68f8a80b55a4b79bfdd.tar.xz
urpmi-a73a3e74e32ec5360b62c68f8a80b55a4b79bfdd.zip
*** empty log message ***
Diffstat (limited to 'urpmi.update')
-rwxr-xr-xurpmi.update15
1 files changed, 12 insertions, 3 deletions
diff --git a/urpmi.update b/urpmi.update
index 7346de86..1982d287 100755
--- a/urpmi.update
+++ b/urpmi.update
@@ -20,6 +20,15 @@
#use strict qw(subs vars refs);
use urpm;
+# for i18n
+use POSIX;
+use Locale::GetText;
+
+setlocale (LC_ALL, "");
+Locale::GetText::textdomain ("urpmi");
+
+import Locale::GetText I_;
+*_ = *I_;
sub main {
my (@toupdates, %options);
@@ -30,7 +39,7 @@ sub main {
/^--?c/ and $options{noclean} = 0, next;
/^--?f/ and $options{force} = 1, next;
/^--?noa/ and next; #- default, keeped for compability.
- /^-/ and die "unknown options \"$_\"\n";
+ /^-/ and die sprintf(_("unknown options \"%s\"\n"), $_);
push @toupdates, $_;
}
@@ -38,9 +47,9 @@ sub main {
my @entries = map { $_->{name} } @{$urpm->{media}};
if ($options{all}) {
- @entries == 0 and die "nothing to update (use urpmi.addmedia to add a media)\n";
+ @entries == 0 and die _("nothing to update (use urpmi.addmedia to add a media)\n");
} else {
- @toupdates == 0 and die "missing the entry to update\n(one of " . join(", ", @entries) . ")\n";
+ @toupdates == 0 and die sprintf(_("missing the entry to update\n(one of %s)\n"), join(", ", @entries));
$urpm->select_media(@toupdates);
#- force ignored media to be returned alive.