en un clic
i18n-context
// Add gettext context for ambiguous user-facing strings and repair affected PO translations.
// Add gettext context for ambiguous user-facing strings and repair affected PO translations.
Rewrite every `docs/*/game/changelog/{order}.stable-{semver}.md` from a ref range. Default `--limit=20`.
Add Cataclysm-BN Lua API bindings for global game functions, utility libraries, constants, callbacks, and domain-specific Lua namespaces.
Add comprehensive Cataclysm-BN Lua bindings for complex C++ classes with methods, inheritance, constructors, properties, operators, and ownership rules.
Add simple Cataclysm-BN Lua bindings for string_id types, enums, and basic read-only C++ types. Use when exposing straightforward C++ types to Lua.
Write or modify Cataclysm-BN Deno/TypeScript scripts. Use for scripts, tools, migrations, generators, git hooks, and CLI utilities.
Quick reference for Cataclysm-BN Lua binding macros, Luna usertypes, libraries, documentation, type patterns, build steps, and common errors.
| name | i18n-context |
| description | Add gettext context for ambiguous user-facing strings and repair affected PO translations. |
| compatibility | Requires git, rg, gettext tools, and Python. |
Use this when one English msgid has multiple meanings and a locale needs different translations.
msgfmt or printf checks fail for the touched locale.msgfmt/printf failures as pre-existing when this task touches that locale.rg -n 'msgid "<word>"|msgctxt .*\nmsgid "<word>"' lang/po/<lang>.porg -n '"<word>"|translate_marker\( "<word>" \)|_\( "<word>" \)' data srcpgettext( "short specific context", "text" ).translate_marker_context( "short specific context", "text" ).{ "ctxt": "short specific context", "str": "text" } or matching plural fields.{ "text": { "ctxt": "short specific context", "str": "text" } }.std::string, convert it to translation so contextual JSON can load.time format, map extra, music genre, damage type.lang/po/<lang>.po for each new msgctxt; do not rely on the old shared msgstr.rg -C2 -i '<term>' lang/po/ko.po | rg -v '^(#:|--)' | head -n 20python3 lang/extract_json_strings.py -i data/json -o /tmp/catabn-i18n-context.pot --tracked-onlymsgfmt -f -c -o /tmp/ko.mo lang/po/ko.po./tools/check_po_printf_format.py./build-scripts/lint-json.sh.pgettext and translate_marker_context.ctxt and updated PO entries.