From 22aec9a0ff3ad165fa89e03da2e01e8a78e6a670 Mon Sep 17 00:00:00 2001 From: Markus Meissner Date: Sun, 24 Nov 2024 21:47:55 +0100 Subject: [PATCH] skip on weblate commit --- .github/workflows/build.yml | 32 +++++++++++++++++++++++++++----- 1 file changed, 27 insertions(+), 5 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 0742971ef9..62913d69b6 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -6,19 +6,38 @@ on: permissions: contents: write -concurrency: - group: ${{ github.ref }} - cancel-in-progress: true - jobs: + check-weblate-commit: + runs-on: ubuntu-latest + steps: + - name: check commit message and cancel self - if Weblate Commit + if: contains(github.event.head_commit.message, 'Translated using Weblate') + uses: andymckay/cancel-action@0.2 + + - name: TODO - start delayed (15mins?) full build + if: contains(github.event.head_commit.message, 'Translated using Weblate') + run: echo "dummy" + + - name: busy wait until cancel - if weblate commit + if: contains(github.event.head_commit.message, 'Translated using Weblate') + run: | + echo "busy wait" + sleep inf + full-build: + needs: [ check-weblate-commit ] + concurrency: + group: ${{ github.ref }} + cancel-in-progress: true + runs-on: ubuntu-latest container: image: sphinxdoc/sphinx #options: --user 1001 (only if we don't need apt-get) + env: MAIN_LANGS: en - OTHER_LANGS: es fr ru nl it ja el bg da et fi lv lt pl pt ro sv sk sl cs hu zh_CN + OTHER_LANGS: de es fr ru nl it ja el bg da et fi lv lt pl pt ro sv sk sl cs hu zh_CN steps: - name: Install git @@ -37,6 +56,7 @@ jobs: mkdir -p dist/en mkdir -p build/en/doctrees sphinx-build -j auto -b html -D language=en -d build/en/doctrees source dist/en + # remove/cleanup dist/en/_sources - name: upload quick build artifact id: upload-quick @@ -93,8 +113,10 @@ jobs: mkdir -p dist/$lang mkdir -p build/$lang/doctrees sphinx-build -j auto -b html -D language=$lang -d build/$lang/doctrees source dist/$lang + # remove/cleanup dist/$lang/_sources done + - name: upload full build artifact id: upload-full uses: actions/upload-artifact@v4