From 855d425224dd6ddd05959deaab0dc17ec2a5fd2a Mon Sep 17 00:00:00 2001 From: Mitchell Tesch Date: Sun, 10 Mar 2024 10:38:58 +1000 Subject: [PATCH] workflow test --- .github/workflows/documentation.yml | 35 +++++++++++++---------------- 1 file changed, 16 insertions(+), 19 deletions(-) diff --git a/.github/workflows/documentation.yml b/.github/workflows/documentation.yml index 0b937a4..add3b8a 100644 --- a/.github/workflows/documentation.yml +++ b/.github/workflows/documentation.yml @@ -1,27 +1,24 @@ -name: documentation +name: "Sphinx: Render docs" -on: [push, pull_request, workflow_dispatch] - -permissions: - contents: write +on: push jobs: - docs: + build: runs-on: ubuntu-latest + permissions: + contents: write steps: - - uses: actions/checkout@v3 - - uses: actions/setup-python@v3 - - name: Install dependencies - run: | - pip install -r requirements-dev.txt - - name: Sphinx build - run: | - sphinx-build docs _build - - name: Deploy to GitHub Pages + - uses: actions/checkout@v4 + - name: Build HTML + uses: ammaraskar/sphinx-action@master + - name: Upload artifacts + uses: actions/upload-artifact@v4 + with: + name: html-docs + path: docs/build/html/ + - name: Deploy uses: peaceiris/actions-gh-pages@v3 - if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/main' }} + if: github.ref == 'refs/heads/main' with: - publish_branch: gh-pages github_token: ${{ secrets.GITHUB_TOKEN }} - publish_dir: _build/ - force_orphan: true \ No newline at end of file + publish_dir: docs/build/html \ No newline at end of file