GNOME translation scripts

This page is a repository of contributed scripts that can be used by GNOME translators.

  • review by LeonardoFontenelle is a script for proof reading your own or someone else's translation. It will download the current translation from GNOME's Damned Lies server and provide a nice diff, among other checks. If you are interested, download it, chmox +x it, and run review --help for more information. It depends optionally on subversion and translate-toolkit; and in rare situations you may need Zenity. After running the script, you'll be able to see the differences (1) between the current local version of the translation and the current version in damned-lies -- useful for reporting your own work to the rest of the team; or (2) between the the current local version and the local version before you ran the script -- useful for reporting the translator the fixes you made while proof-reading his work.

  • zzgrep by LeonardoFontenelle is a terminology compliance checker script. It will recursively find every message catalog which name is or ends with $lang.po (e.g. pt_BR.po, eog.HEAD.pt_BR.po) under the current directory. Then, for each message catalog found, it will look for original messages containing the provided regular expression, and mark these translations as fuzzy. If a regular expression is provided for translated messages, only the messages not containing the regular expressions will be marked as fuzzy. The search is not case sensitive, and only whole words will be matched. Run zzgrep --help for more information, and then play with the --dry-run option to understand how the script works.

  • gnome-i18n-manage-vcs is a script that allows to checkout all or a subset of the repositories of a GNOME release, and download the respective latest PO files from damned-lies. Then, you update the PO files using your favorite editor or script, and finally you use the same script to commit those changes automatically. See blog post with description. It currently works with Subversion and Git.

  • This Perl command will summarize number of translated, fuzzy and untranslated strings in po files in the directory:

perl -e 'my $tra, $fuz, $unt, @outp; foreach (@ARGV) {@outp = `msgfmt -cv $_ 2>&1`;  if($outp[0] =~ /(\d*) translated/) { $tra += $1; } if($outp[0] =~ /(\d*) fuzzy/) { $fuz += $1; } if($outp[0] =~ /(\d*) untranslated/) { $unt += $1; } }  print "$tra translated, $fuz fuzzy, $unt untranslated\n"' *po

  • ThomasThurman wrote a script for module maintainers to list translators of a program since the most recent release.

  • OUTDATED: is a script that bulk-checks out the whole GNOME SVN repository (which is not used anymore for development as GNOME has moved to Git) but only in /po and help folders. For translators, it allows you to have all translatable files but not the others.


TranslationProject/Scripts (last edited 2011-05-06 11:26:01 by AndreKlapper)