3030 description : Which optional group or groups to install. Use comma delimiter for multiple groups e.g `dev,doc`.
3131 required : false
3232 type : string
33- default : dev
33+ default : dev,doc
34+ build-only :
35+ description : If true, skip the upload and deploy steps (useful for testing the build without deploying to GitHub Pages).
36+ required : false
37+ type : boolean
38+ default : false
3439
3540
3641# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pages
@@ -47,9 +52,7 @@ concurrency:
4752
4853jobs :
4954 deploy :
50- environment :
51- name : github-pages
52- url : ${{ steps.deployment.outputs.page_url }}
55+ environment : ${{ !inputs.build-only && 'github-pages' || '' }}
5356 runs-on : ubuntu-latest
5457 timeout-minutes : ${{ inputs.timeout-minutes }}
5558 defaults :
@@ -70,18 +73,16 @@ jobs:
7073
7174 # ----------------------------------------------
7275 # build documentation
73- # - uv sync installs the project root by default; the composite action
74- # uses --no-install-project, so sync here to bring it in before building
7576 # ----------------------------------------------
7677 - name : build documentation
7778 run : |
78- uv sync
7979 uv run mkdocs build
8080
8181 # ----------------------------------------------
8282 # package and upload artifact for deployment to GitHub Pages
8383 # ----------------------------------------------
8484 - name : Upload artifact
85+ if : ${{ !inputs.build-only }}
8586 uses : actions/upload-pages-artifact@v4
8687 with :
8788 path : ${{ inputs.working-directory }}/site
9192 # deploy page
9293 # ----------------------------------------------
9394 - name : Deploy Docs to GitHub Pages
95+ if : ${{ !inputs.build-only }}
9496 id : deployment
9597 uses : actions/deploy-pages@v4
0 commit comments