add localize tool - reliably check, read, and write language files

This commit is contained in:
stopflock
2026-08-01 11:30:49 -05:00
parent 0e1e9cb2ff
commit b231b48ac1
2 changed files with 236 additions and 0 deletions
+15
View File
@@ -0,0 +1,15 @@
#!/usr/bin/env bash
# Thin wrapper around localize.py — see that file's docstring for full usage.
#
# Examples:
# ./scripts/localize.sh --check
# ./scripts/localize.sh --list --lang de
# ./scripts/localize.sh --get --lang en --key node.title
# ./scripts/localize.sh --write --lang es --key node.checkingNodeStatusTitle "Comprobando estado"
set -euo pipefail
SCRIPT_DIR="$(cd "$(dirname "${BASH_SOURCE[0]}")" && pwd)"
PYTHON_BIN="${PYTHON_BIN:-python3}"
exec "$PYTHON_BIN" "$SCRIPT_DIR/localize.py" "$@"