From f6dac55bb794aae7ddda5fe475849ac4e702f7b1 Mon Sep 17 00:00:00 2001 From: nlopess Date: Mon, 19 Dec 2005 17:12:45 +0000 Subject: [PATCH] sync with phpdoc --- docs/scripts/revcheck.php | 57 ++++++++++++++++++++++----------------- 1 file changed, 33 insertions(+), 24 deletions(-) diff --git a/docs/scripts/revcheck.php b/docs/scripts/revcheck.php index 5f036c1d..ab74cee4 100755 --- a/docs/scripts/revcheck.php +++ b/docs/scripts/revcheck.php @@ -37,7 +37,8 @@ the actual english xml files, and print statistics If you specify >, the output is an html file. Read more about Revision comments and related - funcionality in the PHP Documentation Howto. + functionality in the PHP Documentation Howto: + http://php.net/manual/howto/translation-revtrack.html Authors: Thomas Schöfbeck Gabor Hojtsy @@ -82,9 +83,9 @@ $CSS = array( REV_WIP => "wip", ); -// Option for the link to cvs.php.net: normal: "&f=h" -// long diff: "&f=h&num=10", unified (text): "&f=u" -define("CVS_OPT", "&ty=u"); +// Option for the link to cvs.php.net: +define('CVS_OPT', '&view=patch'); +define('CVS_OPT_NOWS', '&view=diff&diff_format=h'); // Initializing variables from parameters $LANG = $argv[1]; @@ -368,7 +369,10 @@ function get_old_files($dir) $special_files = array( // french - 'translation.xml' + 'LISEZ_MOI.txt', + 'TRADUCTIONS.txt', + 'Translators', + 'translation.xml' // todo: add all missing languages ); @@ -640,7 +644,7 @@ print ($navbar); if (!empty($translation["intro"])) { print ''; print '
' . - $translation['intro'] . '

'; + $translation['intro'] . ''; } // ========================================================================= @@ -816,33 +820,33 @@ END_OF_MULTILINE; // This was the previous directory [first] $prev_dir = $new_dir = $DOCDIR."en"; - + // Go through all files collected foreach ($files_status as $num => $file) { - + // Make the maintainer a link, if we have that maintainer in the list if (isset($maint_by_nick[$file["maintainer"]])) { $file["maintainer"] = '' . $file["maintainer"] . ''; } - + // If we have a 'numeric' revision diff and it is not zero, // make a link to the CVS repository's diff script if ($file["revision"][2] != "n/a" && $file["revision"][2] !== 0) { - $url = 'http://cvs.php.net/diff.php/' . + $url = 'http://cvs.php.net/viewcvs.cgi/' . preg_replace( "'^".$DOCDIR."'", 'smarty/docs/', $file['full_name']) . - '?r1=' . $file['revision'][1] . - '&r2=' . $file['revision'][0] . - CVS_OPT; - $url_ws = $url . '&ws=0'; + '?tr1=' . $file['revision'][1] . '&tr2=' . $file['revision'][0] . + '&r1=text&r2=text'; + $url_ws = $url . CVS_OPT_NOWS; + $url .= CVS_OPT; $file['short_name'] = ''. $file["short_name"] . ' '. '[NoWS]'; } - + // Guess the new directory from the full name of the file $new_dir = dirname($file["full_name"]); - + // If this is a new directory, put out old dir lines if ($new_dir != $prev_dir && isset($lines)) { echo $prev_diplay_dir; @@ -851,7 +855,7 @@ END_OF_MULTILINE; $lines = ''; $line_number = 0; - + // Store the new actual directory $prev_dir = $new_dir; } @@ -879,11 +883,12 @@ END_OF_MULTILINE; // echo the last dir and $lines echo "$prev_diplay_dir ($line_number)"; echo $lines; - + print("\n

 

\n$navbar

 

\n"); - + } + // ========================================================================= // Work in progress table goes here // ========================================================================= @@ -1012,7 +1017,7 @@ if ($count > 0) { $prev_dir = $new_dir; } - print "$short_file" . + print "$short_file" . "$info[0]\n"; } print "\n

 

\n$navbar

 

\n"; @@ -1024,7 +1029,7 @@ $count = count($old_files); if ($count > 0) { print "" . "\n" . - "\n"; foreach($old_files as $file => $info) { @@ -1033,13 +1038,13 @@ if ($count > 0) { // Guess the new directory from the full name of the file $new_dir = dirname($file); - + // If this is a new directory, put out dir headline if ($new_dir != $prev_dir) { - + // Print out directory header if not "." print "\n"; - + // Store the new actual directory $prev_dir = $new_dir; } @@ -1048,6 +1053,10 @@ if ($count > 0) { "\n"; } print "
" . + "
" . " Not in EN Tree ($count files):kB
$new_dir
$info[0]
\n

 

\n$navbar

 

\n"; + + + + }