рассылка русскоязычной группы пользователей и разработчиков KDE
 help / color / mirror / Atom feed
From: "Черепанов Андрей" <sibskull@mail.ru>
To: "KDE рассылка" <kde-russian@lists.kde.ru>
Subject: [kde-russian] Множественные формы
Date: Tue, 13 Apr 2004 10:10:35 +0000
Message-ID: <200404131010.35512.sibskull@mail.ru> (raw)

Я начал ревизию ошибок во множественных формах наших переводов. Ветку 3.2 
исправил. Сейчас исправляю HEAD. В конце сообщения приведён скрипт, которым я 
проверяю. Он, правда, не проверяет, переведено ли сообщение вообще и в 
обязательном порядке требует указания трёх '%n' в переводе. Прошу проверять 
ваши переводы перед выкладыванием.

---------------------------------------------------------------
#!/usr/bin/perl

$file = $ARGV[0];
open(F,"$file") or die("Cannot open file $file");
$type = 0;
while(<F>) {
        if(/^#/) { next; }
        if(/^msgid "(.*)"$/) { $type=1; $id=$1; next; }
        if(/^msgstr "(.*)"$/) { $type=2; $str=$1; next; }
        if(/^$/) {
                $type=0;
                # Check forms
                # print "$id\n\t$str\n";
                if($id =~ /^_n:/) {
                        if(not $str =~ /%n.*%n.*%n/) {
                                print "Failed $file\n";
                                exit;
                        }
                }
                next;
        }
        if(/^(\s+)?"(.*)"$/) {
                # Merge strings
                if($type==1) { $id.=$2; }
                if($type==2) { $str.=$2; }
        }
}
close F;

-- 
Андрей Черепанов
sibskull@mail.ru



                 reply	other threads:[~2004-04-13 10:10 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=200404131010.35512.sibskull@mail.ru \
    --to=sibskull@mail.ru \
    --cc=kde-russian@lists.kde.ru \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

рассылка русскоязычной группы пользователей и разработчиков KDE

This inbox may be cloned and mirrored by anyone:

	git clone --mirror http://lore.altlinux.org/kde-russian/0 kde-russian/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 kde-russian kde-russian/ http://lore.altlinux.org/kde-russian \
		kde-russian@lists.kde.ru
	public-inbox-index kde-russian

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://lore.altlinux.org/org.altlinux.lists.kde-russian


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git