Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 33 additions & 0 deletions .github/workflows/L10n.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: test

on:
workflow_dispatch:
push:
paths:
- 'po/'

jobs:
get-langs-changed:
runs-on: ubuntu-latest
outputs:
languages: ${{ steps.languages.outputs.languages }}
steps:
- uses: actions/checkout@v3
- id: languages
shell: bash
run: |
content="$(find . -mindepth 1 -maxdepth 1 -type d -printf '"%P"\n' | sort | tr '\n' ',' | sed 's|,$||')"
echo "languages=[$content]" >> $GITHUB_OUTPUT
working-directory: po

# GitHub Actions editor complains "array was expected but string was found", and it is OK
build-translated-docs:
needs: [get-langs-changed]
strategy:
max-parallel: 2
fail-fast: false
matrix:
language: ${{ fromJSON(needs.get-langs-changed.outputs.languages) }}
uses: ./.github/workflows/docs.yml
with:
language: ${{ matrix.language }}
9 changes: 9 additions & 0 deletions .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,13 @@ name: Docs
on:
push:
pull_request:
workflow_dispatch:
workflow_call:
inputs:
language:
required: false
type: string
default: ''

permissions:
contents: read
Expand All @@ -25,6 +32,7 @@ jobs:
- name: Sphinx build
run: |
echo "::add-matcher::.github/matchers/sphinx.json"
test -n "${{ inputs.language }}" && SPHINXOPTS+=" -D language=${{ inputs.language }}"
make -C docs/ html SPHINXOPTS="${SPHINXOPTS}"
echo "::remove-matcher owner=sphinx::"
env:
Expand All @@ -51,6 +59,7 @@ jobs:
pip install -U -r requirements.txt
- name: Sphinx linkcheck
run: |
test -n "${{ inputs.language }}" && SPHINXOPTS+=" -D language=${{ inputs.language }}"
make -C docs/ linkcheck SPHINXOPTS="${SPHINXOPTS}"
env:
SPHINXOPTS: -n -W -a --keep-going
Expand Down