The attached patch stops noting down a outdated warning to XML of translations.
At present, if a translation is outdated, such warning is written to XML of
translations:
<!-- English Revision: 659902:686549 (outdated) -->
Because of this if we modify an English doc all translations of it are changed
too.
This warning is somewhat useful, but IMHO this is more harmful.
I don't want to see lots of "update transformations" logs.
http://svn.eu.apache.org/viewvc/httpd/httpd/trunk/docs/manual/mod/mpm_common.xml.ja?view=log
If you want to know whether a translation up-to-date or not, you can see meta
file or generated HTML.
Regards,
Takashi
Index: docs-build/trunk/lib/metafile.pl
===================================================================
--- docs-build/trunk/lib/metafile.pl (revision 711158)
+++ docs-build/trunk/lib/metafile.pl (working copy)
@@ -192,7 +192,7 @@
if ($reven) {
my $curpath = docpath("$dirname$_");
- my ($rev, $orev);
+ my ($rev);
# grab the revision info from the source file
sysopen(FILE, $curpath, O_RDONLY)
@@ -200,12 +200,12 @@
{
local $_;
while (<FILE>) {
- $rev = $1, $orev=$2, last
+ $rev = $1, last
if /<!--\s*English\s+Revision:\s*([^\s:]+)
- (?::(\S+)\s+\(outdated\))?\s+-->/xi
+ (?::\S+\s+\(outdated\))?\s+-->/xi
or
/<!--\s*English\s+Revision:\s*(\S+)\s+
- (?:\(outdated:\s*(\S+)\s*\)\s+)?-->/xi;
+ (?:\(outdated:\s*\S+\s*\)\s+)?-->/xi;
}
}
close(FILE)
@@ -213,43 +213,6 @@
# if outdated, take some action
if ($rev and $rev ne $reven) {
- # note the actual revision in the source file
- unless ($orev and $orev eq $reven) {
- my $cont;
- sysopen(FILE, $curpath, O_RDONLY)
- or die "could not open file '$curpath' ($!), stopped";
- {
- local $/; # slurp mode
- $cont = <FILE>;
- }
- close(FILE)
- or die "could not close file '$curpath' ($!), stopped";
-
- unless (
- $cont =~ s{<!--\s*English\s+Revision:\s*([^\s:]+)
- (?::\S+\s+\(outdated\))?\s+-->}
- {<!-- English Revision: $1:$reven (outdated) -->}ix
- ) {
- $cont =~ s{<!--\s*English\s+Revision:\s*(\S+)\s+
- (?:\(outdated[^)]*\)\s+)?-->}
- {<!-- English Revision: $1:$reven (outdated) -->}ix
- }
-
- sysopen(FILE, "$curpath.tmp", O_WRONLY | O_CREAT | O_TRUNC)
- or die "could not open file '$curpath.tmp' ($!),
stopped";
- print FILE $cont
- or die "could write file '$curpath.tmp' ($!), stopped";
- close(FILE)
- or die "could not close file '$curpath.tmp' ($!),
stopped";
-
- rename "$curpath.tmp", $curpath
- or die "could not rename $curpath.tmp -> $curpath ".
- "($!), stopped";
-
- print substr($dirname, 1), $_, " adjusted (refers to: ",
- $rev, ", current is: $reven)\n";
- }
-
# record the filename for later output on the terminal
$curpath = docpath(".outdated.$lang");
sysopen(FILE, $curpath, O_WRONLY | O_CREAT | O_APPEND)
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]