diff options
Diffstat (limited to 'justfile')
-rw-r--r-- | justfile | 19 |
1 files changed, 18 insertions, 1 deletions
@@ -1,4 +1,4 @@ -default: +_default: @just --list # Create a new language pack @@ -41,3 +41,20 @@ update-language-pack locale: FB_PATH="$PWD" cd "language-packs/fietsboek-i18n-{{ locale }}" pybabel update -d "fietsboek_i18n_{{ locale }}/locale" -l {{ locale }} -i "$FB_PATH/fietsboek/locale/fietslog.pot" + +# Initializes a new built-in language +init-language locale: + pybabel init -d fietsboek/locale -l {{ locale }} -i fietsboek/locale/fietslog.pot + cp -r fietsboek/locale/en/html fietsboek/locale/{{ locale }}/ + +# Update the built-in message catalogue +update-language locale: + pybabel update -d fietsboek/locale -l {{ locale }} -i fietsboek/locale/fietslog.pot + +# Compile the given built-in language +compile-language locale: + pybabel compile -d fietsboek/locale -l {{ locale }} -i fietsboek/locale/{{ locale }}/LC_MESSAGES/messages.po + +# Extract new messages from the source files +extract-messages: + pybabel extract -F babel.cfg -o fietsboek/locale/fietslog.pot --input-dirs=fietsboek |