build/i18n-add-language: fix regexp
authorPaul Donald <newtwen@gmail.com>
Wed, 3 Jan 2024 16:09:04 +0000 (16:09 +0000)
committerPaul Donald <newtwen@gmail.com>
Wed, 3 Jan 2024 16:09:12 +0000 (16:09 +0000)
prevents zh, nb, bn
allows bn_BD, nb_NO, pt_BR, zh_Hans, zh_Hant

Signed-off-by: Paul Donald <newtwen@gmail.com>
build/i18n-add-language.sh

index 94568000e11c2e54896820cd944c37b1f859a2b7..951985253eb0f55a8e24ea8a863f45fd0bf932c8 100755 (executable)
@@ -6,7 +6,7 @@ if [ "$#" -eq 0 ]; then
        echo "Hint: run in the root of the luci repo or in your luci-app-* folder."
 
        # get existing language codes from luci.mk
-       language_codes=$(grep -o 'LUCI_LANG\.[a-zA-Z]*' $(dirname "$0")/../luci.mk | cut -d '.' -f 2 | sort -u)
+       language_codes=$(grep -o 'LUCI_LANG\.[a-zA-Z_-]*' $(dirname "$0")/../luci.mk | cut -d '.' -f 2 | sort -u)
        LANGS=$language_codes
 
 else