sphinx.yml 875 B

12345678910111213141516171819202122232425262728293031323334353637
  1. name: Sphinx
  2. on:
  3. pull_request:
  4. paths:
  5. - "**/*.rst"
  6. push:
  7. paths:
  8. - "**/*.rst"
  9. permissions:
  10. contents: "read"
  11. concurrency:
  12. group: ${{ github.workflow }}-${{ github.ref }}
  13. cancel-in-progress: true
  14. jobs:
  15. sphinx:
  16. name: Sphinx reStructuredText validity
  17. runs-on: ubuntu-latest
  18. timeout-minutes: 1
  19. steps:
  20. - name: Checkout repository
  21. uses: actions/checkout@v4
  22. - name: Cache pip
  23. uses: actions/cache@v4
  24. with:
  25. path: ~/.cache/pip
  26. key: ${{ runner.os }}-pip-sphinx-lint
  27. - name: Install sphinx-lint
  28. run: |
  29. pip install --user sphinx-lint
  30. - name: Check Sphinx document sources
  31. run: |
  32. git ls-files --cached -z -- '*.rst' \
  33. | xargs --null -- python -m sphinxlint --enable all --disable trailing-whitespace --max-line-length 2000