Skip to content

Commit

Permalink
Build Python API docs in the CI
Browse files Browse the repository at this point in the history
  • Loading branch information
tronical committed Feb 8, 2025
1 parent 74f1674 commit 355a343
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 1 deletion.
10 changes: 9 additions & 1 deletion .github/workflows/build_docs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,13 @@ jobs:
run: pnpm run docs
working-directory: api/node

- name: Install uv
uses: astral-sh/setup-uv@v5

- name: "Python docs"
run: uv run pdoc slint -o docs
working-directory: api/python

- name: Generate a token
if: ${{ github.ref == 'refs/heads/master' }}
id: app-token
Expand Down Expand Up @@ -181,10 +188,11 @@ jobs:
target/cppdocs/html
docs/astro/dist
api/node/docs
api/python/docs
docs/site
- name: "Check for docs warnings in internal crates"
run: cargo doc --workspace --no-deps --all-features --exclude slint-node --exclude pyslint --exclude mcu-board-support --exclude printerdemo_mcu --exclude carousel --exclude test-* --exclude plotter --exclude uefi-demo --exclude ffmpeg --exclude gstreamer-player --exclude slint-cpp --exclude slint-python
- name: Clean cache # Don't cache docs to avoid them including removed classes being published
run: |
rm -rf target/doc target/cppdocs api/node/docs
rm -rf target/doc target/cppdocs api/node/docs api/python/docs
2 changes: 2 additions & 0 deletions .github/workflows/nightly_snapshot.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -445,6 +445,8 @@ jobs:
mkdir -p $output_path/docs/node
cp -a ../api/node/docs/* $output_path/docs/node/
mkdir -p $output_path/docs/python
cp -a ../api/python/docs/* $output_path/docs/python/
mkdir -p $output_path/docs/slint
cp -a ../docs/astro/dist/* $output_path/docs/slint/
Expand Down

0 comments on commit 355a343

Please sign in to comment.