Skip to content
Merged
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
2 changes: 1 addition & 1 deletion .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -133,4 +133,4 @@ jobs:
with:
python-version: '3.14'
- name: Check if documentation can be built
run: uv run --only-group docs mkdocs build --strict
run: uv run --only-group docs zensical build --strict
37 changes: 28 additions & 9 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -234,14 +234,16 @@ jobs:
if: ${{ github.event_name != 'release' }}
run: uv publish --trusted-publishing always --dry-run wheels-*/*

publish-docs:
build-docs:
name: Build documentation
runs-on: ubuntu-24.04
needs: publish
permissions:
contents: write
steps:
- name: Check out # zizmor: ignore[artipacked] -- required for publishing documentation to `gh-pages` branch
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
with:
persist-credentials: false

- name: Install uv
uses: astral-sh/setup-uv@cec208311dfd045dd5311c1add060b2062131d57 # v8.0.0
Expand All @@ -255,10 +257,27 @@ jobs:
with:
python-version: '3.14'

- name: Deploy documentation
if: ${{ github.event_name == 'release' }}
run: uv run --only-group docs mkdocs gh-deploy --force
- name: Build documentation
run: uv run --only-group docs zensical build --clean

- name: '[dry-run] Deploy documentation'
if: ${{ github.event_name != 'release' }}
run: uv run --only-group docs mkdocs gh-deploy --help
- name: Upload documentation as artifact
id: deployment
uses: actions/upload-pages-artifact@7b1f4a764d45c48632c6b24a0339c27f5614fb0b # v4
with:
path: site

publish-docs:
name: Publish documentation
runs-on: ubuntu-24.04
needs: build-docs
permissions:
contents: write
id-token: write
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
if: ${{ github.event_name == 'release' }}
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@cd2ce8fcbc39b97be8ca5fce6e763baed58fa128 # v5.0.0
2 changes: 1 addition & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ venv.bak/
# Rope project settings
.ropeproject

# mkdocs documentation
# Zensical documentation
/site

# mypy
Expand Down
9 changes: 9 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,4 +1,13 @@
repos:
- repo: local
hooks:
- id: copy-changelog-docs
name: copy changelog to docs
entry: ./scripts/copy-changelog.sh
language: system
pass_filenames: false
files: ^CHANGELOG\.md$

- repo: https://github.com/pre-commit/pre-commit-hooks
rev: "v6.0.0"
hooks:
Expand Down
1 change: 0 additions & 1 deletion docs/CHANGELOG.md

This file was deleted.

Loading