linkchecker/.github/workflows/publish-pages.yml
Chris Mayo 51c6b3ef2f Allow sphinx-rtd-theme to pick the versions of sphinx & docutils
From version 1.1.0 sphinx-rtd-theme adds upper bounds for compatible
versions of sphinx and docutils.
2023-01-18 19:22:50 +00:00

50 lines
1.4 KiB
YAML

name: Publish LinkChecker Documentation on GitHub Pages
on:
push:
branches: ["master"]
release:
types: [released]
jobs:
run:
runs-on: ubuntu-latest
permissions:
contents: write
steps:
- uses: actions/checkout@v3
# Needed for hatch-vcs to extract LinkChecker version from tag
# https://github.com/actions/checkout/issues/249
with:
fetch-depth: 0
- name: Install Ubuntu packages
run: sudo apt install graphviz
# Ensure sphinx-autogen is installed in PATH
- name: Setup Python
uses: actions/setup-python@v4
with:
python-version: "3.x"
- name: Install Python packages
run: |
pip install dnspython beautifulsoup4 requests \
hatchling hatch-vcs
# Allow sphinx-rtd-theme to choose the versions of sphinx & docutils
pip install sphinx-rtd-theme
pip install sphinx-epytext sphinx-sitemap
- name: Build
run: |
python3 -m hatchling build -t sdist --hooks-only
make -C doc html
- name: Publish
uses: peaceiris/actions-gh-pages@de7ea6f8efb354206b205ef54722213d99067935
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./doc/html
commit_message: ${{ github.event.head_commit.message }}