File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -33,17 +33,35 @@ jobs:
3333 sudo apt-get update
3434 sudo apt-get install -y doxygen graphviz
3535 python3 -m pip install --upgrade pip
36- # Ensure mkdocs plugins in mkdocs.yml are available
3736 python3 -m pip install mkdocs mkdocs-material pymdown-extensions
3837
39- # Build API docs first so mkdocs can find docs/api/index.html referenced in nav
40- - name : Build Doxygen
38+ - name : Build docs (Makefile: doxygen + mkdocs)
4139 run : |
42- # Use repo Doxyfile; fallback to root if needed
43- doxygen docs/Doxyfile || doxygen Doxyfile
44- # Ensure doxygen HTML ends up in docs/api (expected by mkdocs.yml nav)
45- if [ -d html ]; then mkdir -p docs/api && cp -a html/. docs/api/; fi
46- if [ -d docs/html ]; then mkdir -p docs/api && cp -a docs/html/. docs/api/; fi
40+ make clean document
41+
42+ - name : Upload artifact
43+ uses : actions/upload-pages-artifact@v3
44+ with :
45+ path : site
46+
47+ deploy :
48+ if : >
49+ ${{
50+ (github.event_name == 'push') ||
51+ (github.event_name == 'pull_request' &&
52+ github.event.pull_request.head.repo.full_name == github.repository)
53+ }}
54+ needs : build
55+ runs-on : ubuntu-latest
56+ environment :
57+ name : github-pages
58+ url : ${{ steps.deployment.outputs.page_url }}
59+ steps :
60+ - id : deployment
61+ uses : actions/deploy-pages@v4
62+ with :
63+ preview : ${{ github.event_name == 'pull_request' }}
64+ fi
4765
4866 - name : Build MkDocs
4967 run : |
6987 steps :
7088 - id : deployment
7189 uses : actions/deploy-pages@v4
90+ with :
91+ preview : ${{ github.event_name == 'pull_request' }}
You can’t perform that action at this time.
0 commit comments