Skip to content

Commit

Permalink
CI: Build and deploy docs to GitHub pages
Browse files Browse the repository at this point in the history
  • Loading branch information
ghisvail committed Aug 13, 2024
1 parent a457e38 commit cd3270d
Showing 1 changed file with 44 additions and 0 deletions.
44 changes: 44 additions & 0 deletions .github/workflows/docs.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,44 @@
name: docs

on:
pull_request:
branches:
- main
push:
branches:
- main
workflow_dispatch:

permissions:
contents: read
pages: write
id-token: write

concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true

jobs:
build-and-deploy:
runs-on: ubuntu-latest
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '3.11'
cache: pip
- name: Install Hatch
uses: pypa/hatch@install
- name: Build docs
run: hatch run docs:build
- name: Upload docs
uses: actions/upload-pages-artifact@v3
with:
name: docs
path: './docs/_build/html'
- name: Deploy docs
id: deployment
uses: actions/deploy-pages@v4

0 comments on commit cd3270d

Please sign in to comment.