aboutsummaryrefslogtreecommitdiffstats
path: root/po
diff options
context:
space:
mode:
authorGuillaume Cottenceau <gc@mandriva.com>2003-06-27 12:44:56 +0000
committerGuillaume Cottenceau <gc@mandriva.com>2003-06-27 12:44:56 +0000
commit58d15a09e3be7b796c977a98e0e9d7acc822705b (patch)
tree2b7c6c3f4f235bfe7d037540167cb0637b994d7c /po
parent5f51b031615efd340426ff73c01ca30a011ab164 (diff)
downloadrpmdrake-58d15a09e3be7b796c977a98e0e9d7acc822705b.tar
rpmdrake-58d15a09e3be7b796c977a98e0e9d7acc822705b.tar.gz
rpmdrake-58d15a09e3be7b796c977a98e0e9d7acc822705b.tar.bz2
rpmdrake-58d15a09e3be7b796c977a98e0e9d7acc822705b.tar.xz
rpmdrake-58d15a09e3be7b796c977a98e0e9d7acc822705b.zip
fix some missing translations for compssUsers ("Mandrake Choices")
Diffstat (limited to 'po')
-rw-r--r--po/Makefile5
-rwxr-xr-xpo/clean_po.pl17
-rwxr-xr-xpo/get_from_compssusers.pl3
3 files changed, 22 insertions, 3 deletions
diff --git a/po/Makefile b/po/Makefile
index b8c3d974..1076b152 100644
--- a/po/Makefile
+++ b/po/Makefile
@@ -20,7 +20,8 @@ all: $(MOFILES)
%.mo: %.po
if [ -z "`echo $(IGNOREPOMS) | grep $<`" ]; then cat $< "$<"m >> "$<"f; else cp $< "$<"f; fi
- msgfmt -o $@ "$<"f
+ ./clean_po.pl "$<"f > "$<"g
+ msgfmt -o $@ "$<"g
merge: $(PGOAL).pot
@for n in $(POFILES); do \
@@ -46,5 +47,5 @@ install:
done
clean:
- @rm -rf *.mo *.pof $(POFILES:%=%t) $(PL_CFILES) $(PGOAL).pot desktopstuff.pot rpmdrake_tmp.pot
+ @rm -rf *.mo *.pof *.pog $(POFILES:%=%t) $(PL_CFILES) $(PGOAL).pot desktopstuff.pot rpmdrake_tmp.pot
diff --git a/po/clean_po.pl b/po/clean_po.pl
new file mode 100755
index 00000000..7022dc74
--- /dev/null
+++ b/po/clean_po.pl
@@ -0,0 +1,17 @@
+#!/usr/bin/perl
+
+# we remove old translations (#~ stuff) because some id's may be shared
+# with what's extracted from the compss, and in such case msgfmt will
+# not put the translations in the mo :(
+
+use MDK::Common;
+
+my $line_number = 0;
+my @contents = cat_($ARGV[0]);
+
+foreach (@contents) {
+ $line_number++;
+ /^#, fuzzy/ && $contents[$line_number+1] =~ /^#~/ and next;
+ /^#~/ and next;
+ print;
+}
diff --git a/po/get_from_compssusers.pl b/po/get_from_compssusers.pl
index 35bfa041..ea350a41 100755
--- a/po/get_from_compssusers.pl
+++ b/po/get_from_compssusers.pl
@@ -2,12 +2,13 @@
use MDK::Common;
-@miss = qw(Development Server);
+@miss = (qw(Development Server Workstation), 'Graphical Environment');
foreach my $line (cat_("../../../gi/perl-install/share/po/$ARGV[0]")) {
$line =~ m|^\Q#: ../../share/compssUsers:999| || ($line =~ m|^msgid "([^"]+)"| && grep { $_ eq $1 } @miss) and do {
$current = 'inside';
print "# DO NOT BOTHER TO MODIFY HERE, BUT IN DRAKX PO\n";
+ $line =~ m|^#:| or print "#: ../../share/compssUsers:999\n";
};
$current eq 'inside' and print $line;
$line =~ m|^$| and do {