Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/docker-ci.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMorris Jobke <hey@morrisjobke.de>2018-08-22 11:35:08 +0300
committerMorris Jobke <hey@morrisjobke.de>2018-08-22 11:35:23 +0300
commitd15addfd3fe80ae1fb6919cb091881423eef306e (patch)
tree8a854e46e78148bf2a251480a9e013d4f9386d7b
parent0e61ff902277596c940bb24fbab416d5e8dcc7a6 (diff)
Add docker container for changelog server tooltranslations-changelogserver-1
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
-rw-r--r--translations/Dockerfile-ChangelogServer7
-rwxr-xr-xtranslations/handleChangelogServerTranslations.sh30
2 files changed, 37 insertions, 0 deletions
diff --git a/translations/Dockerfile-ChangelogServer b/translations/Dockerfile-ChangelogServer
new file mode 100644
index 0000000..f038bba
--- /dev/null
+++ b/translations/Dockerfile-ChangelogServer
@@ -0,0 +1,7 @@
+FROM nextcloudci/translations:translations-19
+
+MAINTAINER Morris Jobke <hey@morrisjobke.de>
+
+ADD handleChangelogServerTranslations.sh /handleChangelogServerTranslations.sh
+ADD translationtool-whatsnew/ /translationtool
+
diff --git a/translations/handleChangelogServerTranslations.sh b/translations/handleChangelogServerTranslations.sh
new file mode 100755
index 0000000..b12b0c8
--- /dev/null
+++ b/translations/handleChangelogServerTranslations.sh
@@ -0,0 +1,30 @@
+#!/bin/sh
+
+# verbose and exit on error
+set -xe
+
+# import GPG keys
+gpg --import /gpg/nextcloud-bot.public.asc
+gpg --allow-secret-key-import --import /gpg/nextcloud-bot.asc
+gpg --list-keys
+
+# fetch git repo
+git clone git@github.com:$1/$2 /app
+
+# extract l10n strings into POT
+php /translationtool/extract-l10n.php /app/data/
+
+# push sources
+tx push -s
+
+# pull translations
+tx pull -f -a --minimum-perc=50
+
+# generate updated XML
+php /translationtool/generate-xml.php /app/data/
+
+# create git commit and push it
+git add .
+git commit -am "[tx-robot] updated from transifex" || true
+git push origin master
+echo "done"