feat: adjustments to netifyd bypasses documentation (#279) #372
This file contains hidden or 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: Update Italian Translation | |
| on: | |
| push: | |
| branches: [main] | |
| workflow_dispatch: | |
| jobs: | |
| update-po-files: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: write | |
| pull-requests: write | |
| env: | |
| OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }} | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install dependencies | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y graphviz | |
| pip install -r requirements.txt | |
| pip install -r locale/requirements.txt | |
| - name: Generate POT files | |
| run: | | |
| sphinx-build -b gettext . locale/pot/ | |
| rm -f locale/pot/download.pot | |
| - name: Translate using AI | |
| run: | | |
| cd locale | |
| OPENAI_API_KEY=${{ secrets.OPENAI_API_KEY }} ./ai_translate.py | |
| rm -rf pot ../*.csv ../_static/high_availability.png | |
| - name: Create Pull Request | |
| id: cpr | |
| uses: peter-evans/create-pull-request@v7 | |
| with: | |
| commit-message: "chore(i18n): update Italian translation" | |
| committer: github-actions[bot] <github-actions[bot]@users.noreply.github.com> | |
| author: ${{ github.actor }} <${{ github.actor_id }}+${{ github.actor }}@users.noreply.github.com> | |
| signoff: false | |
| branch: update-ai-translations | |
| title: '[BOT] Update Italian translation' | |
| body: | | |
| This PR updates po files using AI translation for Italian language. | |
| [Download Italian docs artifact](https://github.com/${{ github.repository }}/actions/runs/${{ github.run_id }}) | |
| draft: false | |
| - name: Build Italian docs | |
| run: | | |
| git checkout update-ai-translations | |
| sphinx-build -b html -D language=it . _build/html/it | |
| - name: Upload Italian docs artifact | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: italian-docs | |
| path: _build/html/it | |