Skip to main content

Convert PO files to Excel Spreadsheets and back.

Project description

pox-convert

PyPI Python License Tests Coverage

Convert .po (gettext) files to Excel spreadsheets and back. Supports fuzzy entries and multiple plural forms.

Screenshot

Usage

PO to Excel

uvx pox-convert export path/to/messages.po

Use globbing to convert multiple files at once:

uvx pox-convert export locales/**/django.po

Options:

-o, --outdir      Output directory (default: current directory)
-f, --filename    Filename template using {lang} and {date} variables
                  (default: translations_{lang}.xlsx)
-l, --language    Override the language metadata from the PO file
--fuzzy           How to handle fuzzy entries: stop, ignore, include (default: stop)

Excel to PO

uvx pox-convert import path/to/translations.xlsx

Options:

-o, --outdir      Output directory (default: current directory)
-f, --filename    Filename template using {lang} variable (default: {lang}.po)

Spreadsheet format

The generated Excel file has the following structure:

id Context Singular Form Translation
1 Hello Hallo
2 adjective Open Offen
3 Goodbye
  • Empty translations are highlighted in yellow with a black border
  • The header row is frozen for easy scrolling
  • Alternating row stripes improve readability
  • Plural forms get additional translation columns
  • Language metadata is stored as a custom document property

Django integration

pox-convert ships with a Django management command that wraps makemessages to skip fuzzy matching:

python manage.py makemessages_nofuzzy -l de

Add pox.contrib.django.pox to your INSTALLED_APPS to use it.

Changelog

1.1.0

  • Programmatic plural hint generation using a safe formula parser.
  • Improved CI coverage reporting.
  • 100% test coverage.

1.0.1

  • Unified CLI with pox-convert entry point.
  • Added Excel-to-PO reverse conversion (xop).
  • Redesigned spreadsheet styles and column headers.
  • Added MIT license, README, and GitHub Actions CI workflow.
  • Full type annotations and stricter linting.

1.0.0

  • Initial release with PO-to-Excel conversion.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pox_convert-1.1.0.tar.gz (538.3 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pox_convert-1.1.0-py3-none-any.whl (22.9 kB view details)

Uploaded Python 3

File details

Details for the file pox_convert-1.1.0.tar.gz.

File metadata

  • Download URL: pox_convert-1.1.0.tar.gz
  • Upload date:
  • Size: 538.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.2 {"installer":{"name":"uv","version":"0.10.2","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for pox_convert-1.1.0.tar.gz
Algorithm Hash digest
SHA256 3403d7f379723bc28a4e964e5121d7e155099af8d253b8110de9b40ad35b6def
MD5 01ab21bda4b258ad5a0ecb23d01af167
BLAKE2b-256 7a7bb063a77b5bfb7372a05424a282ef9a01081f948fdeee745685a6877920bc

See more details on using hashes here.

File details

Details for the file pox_convert-1.1.0-py3-none-any.whl.

File metadata

  • Download URL: pox_convert-1.1.0-py3-none-any.whl
  • Upload date:
  • Size: 22.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.10.2 {"installer":{"name":"uv","version":"0.10.2","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

File hashes

Hashes for pox_convert-1.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 1ab2b9553fb1131c283c9e8b7cb7d3de80035bd0bb2339cd9cbb180aa264f658
MD5 93a9a34f9f170c4ebd7ad733063b1b5f
BLAKE2b-256 56dd8c16cbaa4e302a50f0d9150acd41861ec9fe7b1abfc2c5aa887e91e9a3f2

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page