Security News
Oracle Drags Its Feet in the JavaScript Trademark Dispute
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Potodo, a (almost) flawless TODO/progress listing CLI tool for po files.
Poutils (.po
utils) is is a metapackage to easily install usefull Python tools to use with po files
and potodo
is a part of it! Go check out Poutils to discover the other useful tools for po
file related translation!
pip install potodo
When ran in the french CPython documentation translation it shows:
$ potodo --exclude venv .venv whatsnew c-api/ distutils/
# python-docs-fr (95.31% done)
- bugs.po 29 / 30 ( 96.0% translated).
- copyright.po 6 / 7 ( 85.0% translated), 1 fuzzy.
- license.po 87 / 91 ( 95.0% translated), 2 fuzzy.
# extending (56.81% done)
- building.po 22 / 23 ( 95.0% translated), 1 fuzzy.
- extending.po 120 / 158 ( 75.0% translated), 8 fuzzy.
- index.po 11 / 12 ( 91.0% translated), 1 fuzzy.
- newtypes.po 38 / 89 ( 42.0% translated), 3 fuzzy.
- newtypes_tutorial.po 31 / 123 ( 25.0% translated), 2 fuzzy.
- windows.po 20 / 21 ( 95.0% translated), 1 fuzzy.
[...]
# TOTAL (50.01% done)
To avoid having two translators work on the same file at the same time, one can tell other translations that a file is being translated using an issue or a draft pull request.
potodo
can fetch those issues and display it. It currently work with
Gitea and Github.
For example, in a clone of python-docs-fr you can run:
$ potodo --api-url 'https://git.afpy.org/api/v1/repos/AFPy/python-docs-fr/issues?state=open&type=issues' --exclude .venv
[...]
# extending (56.81% done)
- building.po 22 / 23 ( 95.0% translated), 1 fuzzy, reserved by Starmania.
- extending.po 120 / 158 ( 75.0% translated), 8 fuzzy.
- index.po 11 / 12 ( 91.0% translated), 1 fuzzy.
- newtypes.po 38 / 89 ( 42.0% translated), 3 fuzzy.
- newtypes_tutorial.po 31 / 123 ( 25.0% translated), 2 fuzzy.
- windows.po 20 / 21 ( 95.0% translated), 1 fuzzy.
# faq (90.88% done)
- extending.po 55 / 58 ( 94.0% translated), 3 fuzzy.
- general.po 88 / 98 ( 89.0% translated).
- gui.po 16 / 17 ( 94.0% translated), 1 fuzzy, reserved by Iucounu.
- library.po 139 / 140 ( 99.0% translated).
- programming.po 340 / 389 ( 87.0% translated), 40 fuzzy.
[...]
Notice the reserved by column.
For github it would look like --api-url 'https://api.github.com/repos/ORGANISATION/REPOSITORY/issues?state=open'
.
It's a bit verbose, so maybe hide this in a Makefile or whatever, but this way you can tweak the parameters of the query, typically to filter on a label if needed.
The way potodo
maps issues to files is simple: the path of the file
just has to be present in the issue title, so any issues like:
I'm currently working on faq/extending.po
Je travaille sur extending/index.po
blah blah library/functions.po blah blah
will correctly match their file.
Create a virtual environment
python3 -m venv venv
Activate it
source venv/bin/activate
Install the dev requirements
pip install -r requirements-dev.txt
Install the pre-commit hook
pre-commit install
Install potodo
in a development version
pip install -e .
cache_args
to simplify cache functionality.potodoignore
file-l
--matching-files
Which will print the path of files matching your argumentspotodo
versions.--only-reserved
option to display only reserved filed--reserved-dates
to display when a file was reservedpofiles
to speedup the reading process--interactive
git checkout -b feature/fooBar
/!\
Don't forget to bump the version in potodo/__init__.py
when you're pushing your changes to your branch
git commit -am 'Add some fooBar'
)git push origin feature/fooBar
)FAQs
List .po files to be translated.
We found that potodo demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 3 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.