You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
39 lines
1.2 KiB
39 lines
1.2 KiB
name: Update translatable texts
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- develop
|
|
|
|
jobs:
|
|
translations:
|
|
runs-on: ubuntu-latest
|
|
env:
|
|
TX_TOKEN: ${{ secrets.TX_TOKEN }}
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
- name: Generate translatable texts
|
|
run: |
|
|
python3 tools/extract_pot.py
|
|
- name: Install Transifex client
|
|
if: env.TX_TOKEN
|
|
# Sudo is needed to link the "tx"-command
|
|
run: |
|
|
sudo -H python3 -m pip install setuptools wheel
|
|
sudo -H python3 -m pip install transifex-client
|
|
- name: Push/pull Transifex translations
|
|
if: env.TX_TOKEN
|
|
run: |
|
|
tx push --source --parallel
|
|
tx pull --all --force --parallel
|
|
- name: Compile translations to validate them
|
|
run: |
|
|
python3 tools/make_mo.py
|
|
- name: Push translatable and translated texts back to repo
|
|
uses: stefanzweifel/git-auto-commit-action@v4.5.1
|
|
if: env.TX_TOKEN
|
|
with:
|
|
commit_message: Update translatable texts
|
|
commit_user_name: SABnzbd Automation
|
|
commit_user_email: bugs@sabnzbd.org
|
|
commit_author: SABnzbd Automation <bugs@sabnzbd.org>
|
|
|