]> git.pld-linux.org Git - packages/rpm-build-macros.git/blobdiff - dokuwiki-find-lang.sh
v1.706: find-lang: v1.37 update --with-qm to accept from any path
[packages/rpm-build-macros.git] / dokuwiki-find-lang.sh
old mode 100644 (file)
new mode 100755 (executable)
index 489388c..8965583
@@ -34,19 +34,29 @@ while read dir; do
                ca-valencia)
                        lang=ca@valencia
                ;;
+               hu-formal)
+                       lang=hu
+               ;;
                de-informal)
                        lang=de
                ;;
+               zh-cn)
+                       lang=zh_CN
+               ;;
                *-*)
                        echo >&2 "ERROR: Need mapping for $lang!"
                        rc=1
                ;;
                esac
-               echo "%lang($lang) ${dir#$RPM_BUILD_ROOT}" >> $langfile
+               if [ "$lang" = "en" ]; then
+                       echo "${dir#$RPM_BUILD_ROOT}" >> $langfile
+               else
+                       echo "%lang($lang) ${dir#$RPM_BUILD_ROOT}" >> $langfile
+               fi
        done
 done < $tmp
 
-if [ "$(egrep -v '(^%defattr|^$)' $langfile | wc -l)" -le 0 ]; then
+if [ "$(grep -Ev '(^%defattr|^$)' $langfile | wc -l)" -le 0 ]; then
        echo >&2 "$PROG: Error: international files not found!"
        rc=1
 fi
This page took 0.024978 seconds and 4 git commands to generate.