Welcome, guest | Sign In | My Account | Store | Cart

Notice! PyPM is being replaced with the ActiveState Platform, which enhances PyPM’s build and deploy capabilities. Create your free Platform account to download ActivePython or customize Python with the packages you require and get automatic updates.

Download
ActivePython

potools is unavailable in PyPM, because there aren't any builds for it in the package repositories. Click the linked icons to find out why.

 Python 2.7Python 3.2Python 3.3
Windows (32-bit)
Windows (64-bit)
Mac OS X (10.5+)
Linux (32-bit)
Linux (64-bit)
 
Links
License
GPL

potools

This package contains command line tools to help manage translations.

  • podiff: Shows the differences between two po files. It only cares about the default value, msgid and msgstr, not about position in the file. You can also specify a version control repository with which to compare a file with.

  • pogetnew: Compares two po files and return all new entries that need to be translated. Output is printed to stdout, in the format as a valid po file, so that it can be sent to translator.

  • pocheck: Checks the pot/po file for smells.
    • The Translate Toolkit provides a similar tool called pofilter. Pocheck aims to not duplicate any of the functionality already in pofilter.
  • pounique: Takes several po files (or directories of po files) and return one pofile (or a directory of pofiles) with unique values. It can pick the values either from the last file given, or my making a "best guess".

  • poupdate: Will update the first po file with values from the second.

  • popopulate: Will replace any empty messages with their Default message, if there is one, and mark it as fuzzy.

Installation

Simply run:

pip install potools

or if you are using easy_install:

easy_install potools

Buildout users can add the following part to their buildouts:

[script]
recipe = zc.recipe.egg
eggs = potools

One-liners

podiff
  • Diff all po files in a git repository, with the last committed versions:

    find -name "*.po" -exec podiff --vcs git $(git remote -v | awk 'BEGIN {} NR ==2 {print substr ($2, 1)}') {} \;
    

Changelog

0.3.1 (2013-07-30)
  • poupdate: added new option to determine if fuzzy markers in the target should be removed on update [pysailor]
0.3 (2013-07-30)
  • Added pounique, poupdate and popopulate commands. [regebro]
0.2 (2013-04-23)
  • Also compare (and show) comments in podiff. [jcbrand]
0.1 (2013-03-11)
  • Initial release [jcbrand]

Subscribe to package updates

Download Stats

Last month:1

What does the lock icon mean?

Builds marked with a lock icon are only available via PyPM to users with a current ActivePython Business Edition subscription.

Need custom builds or support?

ActivePython Enterprise Edition guarantees priority access to technical support, indemnification, expert consulting and quality-assured language builds.

Plan on re-distributing ActivePython?

Get re-distribution rights and eliminate legal risks with ActivePython OEM Edition.