Update main.yml #196
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: "Export terms to POEditor" | |
on: | |
push: | |
branches: [ main ] | |
paths-ignore: | |
- 'locales/**' | |
jobs: | |
docs: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v1 | |
- name: Build sphinx terms | |
uses: ammaraskar/[email protected] | |
env: | |
GITHUB_ACTIONS: 1 | |
with: | |
docs-folder: "./" | |
pre-build-command: "apt-get update --allow-releaseinfo-change -y && apt-get install -y pandoc git && make fetchnotebooks && make buildtools" | |
build-command: "sphinx-build -T -b gettext . _build" | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install poeditor | |
- name: Display the dir | |
run: ls -la ./_build | |
shell: bash | |
- name: CHMOD | |
run: sudo chmod a+rw ./_build/docs.pot | |
shell: bash | |
- name: Archive production artifacts | |
uses: actions/upload-artifact@v4 | |
with: | |
name: save-docs-pot | |
path: | | |
./_build/*.pot | |
- name: Upload terms | |
env: | |
POEDITOR_API_TOKEN: ${{ secrets.POEDITOR_API_TOKEN }} | |
POEDITOR_PROJECT_ID: "715168" | |
run: | | |
python upload_terms.py | |
- name: Download terms | |
env: | |
POEDITOR_API_TOKEN: ${{ secrets.POEDITOR_API_TOKEN }} | |
POEDITOR_PROJECT_ID: "715168" | |
run: | | |
python download_translations.py |