From 48be192f1157206e50949debf2091e960c78d680 Mon Sep 17 00:00:00 2001 From: Arthur Schiwon Date: Thu, 15 Jan 2026 21:51:09 +0100 Subject: [PATCH] build: use requirements file from 28 and adjust build logic Signed-off-by: Arthur Schiwon --- .../workflows/generate_catalog_templates.yml | 65 +++++++++-------- .github/workflows/sphinxbuild.yml | 72 ++++++++++--------- requirements.txt | 46 ++++++------ 3 files changed, 99 insertions(+), 84 deletions(-) diff --git a/.github/workflows/generate_catalog_templates.yml b/.github/workflows/generate_catalog_templates.yml index b4bd2fe11..bb0aa8cb5 100644 --- a/.github/workflows/generate_catalog_templates.yml +++ b/.github/workflows/generate_catalog_templates.yml @@ -1,38 +1,47 @@ name: Generate catalog templates (POT) files fetched automatically by transifex on: + workflow_dispatch: push: branches: - - master + - master paths: - - 'user_manual/**' - - '!user_manual/locale/**' + - 'user_manual/**' + - '!user_manual/locale/**' jobs: user_manual: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 - - uses: ammaraskar/sphinx-action@master - with: - docs-folder: "user_manual/" - pre-build-command: pip install -r requirements.txt - build-command: make gettext - - uses: peter-evans/create-pull-request@v4 - with: - commit-message: Updates catalog templates (POT files fetched automatically by transifex) - title: l10n - branch: update-l10n - signoff: true - - uses: pascalgn/automerge-action@v0.15.3 - if: steps.cpr.outputs.pull-request-operation == 'created' - env: - GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}" - MERGE_LABELS: "" - MERGE_RETRIES: 10 - MERGE_RETRY_SLEEP: 60000 - PULL_REQUEST: ${{ github.event.inputs.pull-request-number }} - - uses: hmarr/auto-approve-action@v2.2.1 - if: steps.cpr.outputs.pull-request-operation == 'created' - with: - github-token: "${{ secrets.GITHUB_TOKEN }}" - pull-request-number: ${{ github.event.inputs.pull-request-number }} + - uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 + - uses: actions/setup-python@7f4fc3e22c37d6ff65e88745f38bd3157c663f7c # v4 + with: + python-version: '3.12' + cache: 'pip' + - name: Install pip dependencies + run: pip install -r requirements.txt + - name: Build using Makefile + run: cd user_manual && make gettext + + - uses: peter-evans/create-pull-request@v5 + id: cpr + with: + token: ${{ secrets.COMMAND_BOT_PAT }} + commit-message: "chore(l10n): Updates catalog templates (POT files fetched automatically by transifex)" + title: Updates catalog templates + branch: update-l10n + signoff: true + + - uses: hmarr/auto-approve-action@v3.2.1 + if: steps.cpr.outputs.pull-request-operation == 'created' + with: + github-token: "${{ secrets.GITHUB_TOKEN }}" + pull-request-number: ${{ steps.cpr.outputs.pull-request-number }} + + - uses: pascalgn/automerge-action@v0.15.6 + if: steps.cpr.outputs.pull-request-operation == 'created' + env: + GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}" + MERGE_LABELS: "" + MERGE_RETRIES: 10 + MERGE_RETRY_SLEEP: 60000 + PULL_REQUEST: ${{ steps.cpr.outputs.pull-request-number }} diff --git a/.github/workflows/sphinxbuild.yml b/.github/workflows/sphinxbuild.yml index 380b493a6..7fab1b919 100644 --- a/.github/workflows/sphinxbuild.yml +++ b/.github/workflows/sphinxbuild.yml @@ -11,72 +11,74 @@ jobs: user_manual: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 - - uses: actions/setup-python@v4 + - uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 + - uses: actions/setup-python@7f4fc3e22c37d6ff65e88745f38bd3157c663f7c # v4 with: - python-version: '3.10' - - uses: ammaraskar/sphinx-action@master - with: - docs-folder: "user_manual/" - pre-build-command: pip install -r requirements.txt - build-command: make html + python-version: '3.12' + cache: 'pip' + - name: Install pip dependencies + run: pip install -r requirements.txt + - name: Build using Makefile + run: cd user_manual && make html - name: Pack the results in local tar file shell: bash run: tar czf /tmp/documentation.tar.gz -C user_manual/_build/html . - name: Upload static documentation - uses: actions/upload-artifact@v2.2.4 + uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v6.0.0 with: name: User manual.zip path: "/tmp/documentation.tar.gz" + user_manual-en: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 - - uses: actions/setup-python@v4 + - uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 + - uses: actions/setup-python@7f4fc3e22c37d6ff65e88745f38bd3157c663f7c # v4 with: - python-version: '3.10' - - uses: ammaraskar/sphinx-action@master - with: - docs-folder: "user_manual/" - pre-build-command: pip install -r requirements.txt - build-command: make html-lang-en + python-version: '3.12' + - name: Install pip dependencies + run: pip install -r requirements.txt + - name: Build using Makefile + run: cd user_manual && make html-lang-en + developer_manual: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 - - uses: actions/setup-python@v4 + - uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 + - uses: actions/setup-python@7f4fc3e22c37d6ff65e88745f38bd3157c663f7c # v4 with: - python-version: '3.10' - - uses: ammaraskar/sphinx-action@master - with: - docs-folder: "developer_manual/" - pre-build-command: pip install -r requirements.txt - build-command: make html + python-version: '3.12' + cache: 'pip' + - name: Install pip dependencies + run: pip install -r requirements.txt + - name: Build using Makefile + run: cd developer_manual && make html - name: Pack the results in local tar file shell: bash run: tar czf /tmp/documentation.tar.gz -C developer_manual/_build/html/com . - name: Upload static documentation - uses: actions/upload-artifact@v2.2.4 + uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v6.0.0 with: name: Developer manual.zip path: "/tmp/documentation.tar.gz" + admin_manual: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 - - uses: actions/setup-python@v4 + - uses: actions/checkout@8e8c483db84b4bee98b60c0593521ed34d9990e8 + - uses: actions/setup-python@7f4fc3e22c37d6ff65e88745f38bd3157c663f7c # v4 with: - python-version: '3.10' - - uses: ammaraskar/sphinx-action@master - with: - docs-folder: "admin_manual/" - pre-build-command: pip install -r requirements.txt - build-command: make html + python-version: '3.12' + cache: 'pip' + - name: Install pip dependencies + run: pip install -r requirements.txt + - name: Build using Makefile + run: cd admin_manual && make html - name: Pack the results in local tar file shell: bash run: tar czf /tmp/documentation.tar.gz -C admin_manual/_build/html/com . - name: Upload static documentation - uses: actions/upload-artifact@v2.2.4 + uses: actions/upload-artifact@b7c566a772e6b6bfb58ed0dc250532a479d7789f # v6.0.0 with: name: Administration manual.zip path: "/tmp/documentation.tar.gz" diff --git a/requirements.txt b/requirements.txt index fd0f5dca5..18be24a7f 100644 --- a/requirements.txt +++ b/requirements.txt @@ -1,31 +1,35 @@ alabaster==0.7.13 -Babel==2.12.1 -certifi==2023.5.7 -charset-normalizer==3.1.0 -docutils==0.17.1 +Babel==2.13.1 +certifi==2023.7.22 +charset-normalizer==3.2.0 +docutils==0.18.1 idna==3.4 imagesize==1.4.1 -importlib-metadata==6.6.0 +importlib-metadata==6.8.0 Jinja2==3.1.2 MarkupSafe==2.1.3 -packaging==23.1 -Pillow==9.5.0 -Pygments==2.15.1 -PyYAML==6.0 -reportlab==4.0.4 +packaging==23.2 +Pillow==10.0.1 +Pygments==2.16.1 +PyYAML==6.0.1 +reportlab==4.0.6 requests==2.31.0 -rst2pdf==0.100 +rst2pdf==0.101 smartypants==2.0.1 snowballstemmer==2.2.0 -Sphinx==4.5.0 -sphinx-rtd-theme==1.2.2 -sphinxcontrib-applehelp==1.0.4 -sphinxcontrib-devhelp==1.0.2 -sphinxcontrib-htmlhelp==2.0.1 +Sphinx==7.2.6 +sphinx-copybutton==0.5.2 +sphinx-rtd-theme==1.3.0 +sphinx-rtd-dark-mode==1.3.0 +sphinxcontrib-applehelp==1.0.7 +sphinxcontrib-devhelp==1.0.5 +sphinxcontrib-htmlhelp==2.0.4 sphinxcontrib-jquery==4.1 sphinxcontrib-jsmath==1.0.1 -sphinxcontrib-phpdomain==0.11.0 -sphinxcontrib-qthelp==1.0.3 -sphinxcontrib-serializinghtml==1.1.5 -urllib3==2.0.3 -zipp==3.15.0 +sphinxcontrib-phpdomain==0.11.1 +sphinxcontrib-qthelp==1.0.6 +sphinxcontrib-serializinghtml==1.1.9 +sphinx-toolbox==3.5.0 +sphinx-reredirects==0.1.3 +urllib3==2.0.6 +zipp==3.16.2