1
mirror of https://invent.kde.org/network/falkon.git synced 2024-11-14 11:02:19 +01:00
falkonOfficial/scripts/generate-qmake-translations.sh
nowrep 5b97bb321b [Translations] Updated array of applicationt translations
Also updated script to also generate application translations
2014-01-27 19:29:20 +01:00

34 lines
700 B
Bash
Executable File

#!/bin/bash
#
# Generates list of all translations for qmake .pro
# Plugins translations
PLUGINS="`ls -d ../src/plugins/*/translations`"
for dir in $PLUGINS
do
echo -e "$dir\n"
echo "TRANSLATIONS += \\"
for translation in $dir/*.ts
do
[[ "$translation" == *empty.ts ]] && continue
echo " `echo $translation | awk 'BEGIN{FS="/"}{printf "%s/%s",$5,$6}'` \\"
done
echo -e "\n\n"
done
# App translations
echo -e "../translations\n"
echo "TRANSLATIONS += \\"
for translation in ../translations/*.ts
do
[[ "$translation" == *empty.ts ]] && continue
echo " `echo $translation | awk 'BEGIN{FS="/"}{printf "$$PWD/%s",$3}'` \\"
done
echo -e "\n\n"