Skip to content

Commit

Permalink
Finish Weblate migration
Browse files Browse the repository at this point in the history
  • Loading branch information
Frenzie committed Dec 31, 2019
1 parent adc625b commit 09af114
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 7 deletions.
9 changes: 9 additions & 0 deletions .ci/after_success.sh
Expand Up @@ -9,6 +9,15 @@ set +e
if [ -z "${CIRCLE_PULL_REQUEST}" ] && [ "${CIRCLE_BRANCH}" = 'master' ]; then
echo "CIRCLE_NODE_INDEX: ${CIRCLE_NODE_INDEX}"
if [ "$CIRCLE_NODE_INDEX" = 1 ]; then
echo -e "\\n${ANSI_GREEN}Updating translation source file."
make pot
pushd l10n && {
git -c user.name="KOReader build bot" -c user.email="non-reply@koreader.rocks" \
commit templates/koreader.pot -m "Updated translation source file"
git push --quiet "https://${TRANSLATIONS_GITHUB_TOKEN}@github.com/koreader/koreader-translations.git" master
echo -e "\\n${ANSI_GREEN}Translation update pushed."
}

echo -e "\\n${ANSI_GREEN}Checking out koreader/doc for update."
git clone git@github.com:koreader/doc.git koreader_doc

Expand Down
9 changes: 2 additions & 7 deletions Makefile
Expand Up @@ -489,7 +489,7 @@ DOMAIN=koreader
TEMPLATE_DIR=l10n/templates
XGETTEXT_BIN=xgettext

pot:
pot: po
mkdir -p $(TEMPLATE_DIR)
$(XGETTEXT_BIN) --from-code=utf-8 \
--keyword=C_:1c,2 --keyword=N_:1,2 --keyword=NC_:1c,2,3 \
Expand All @@ -498,14 +498,9 @@ pot:
`find plugins -iname "*.lua"` \
`find tools -iname "*.lua"` \
-o $(TEMPLATE_DIR)/$(DOMAIN).pot
# push source file to Transifex
$(MAKE) -i -C l10n bootstrap
$(MAKE) -C l10n push

po:
$(MAKE) -C l10n pull
# After Weblate migration
#git submodule update --remote l10n
git submodule update --remote l10n


static-check:
Expand Down

0 comments on commit 09af114

Please sign in to comment.