Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/archinstall/locales
diff options
context:
space:
mode:
authorDaniel <blackrabbit256@gmail.com>2022-02-07 01:17:43 +1100
committerGitHub <noreply@github.com>2022-02-06 15:17:43 +0100
commit20e23dcecd2bb4eeb72d324c33a29685c0241035 (patch)
tree5001cc529ba7b08af1da423173553da224b69292 /archinstall/locales
parent1ea6fea1d838f3b4646c9e4eebc9ffbdf45f3149 (diff)
Add locale script (#945)
* Add locales script * Add gitignore exception Co-authored-by: Daniel Girtler <girtler.daniel@gmail.com>
Diffstat (limited to 'archinstall/locales')
-rw-r--r--archinstall/locales/locales_generator.sh12
1 files changed, 12 insertions, 0 deletions
diff --git a/archinstall/locales/locales_generator.sh b/archinstall/locales/locales_generator.sh
new file mode 100644
index 00000000..43e004d4
--- /dev/null
+++ b/archinstall/locales/locales_generator.sh
@@ -0,0 +1,12 @@
+#!/bin/bash
+
+cd $(dirname "$0")/..
+
+find . -type f -iname "*.py" | xargs xgettext -j --omit-header -d base -o locales/base.pot
+
+for file in $(find locales/ -name "base.po"); do
+ echo "Updating: $file"
+ path=$(dirname $file)
+ msgmerge --quiet --width 512 --update $file locales/base.pot
+ msgfmt -o $path/base.mo $file
+done