Skip to content

Fix the GitHub Pages deployment (docs + dashboard) - #11

Merged
chrisflav merged 4 commits into
masterfrom
fix-pages-deploy
Jun 29, 2026
Merged

Fix the GitHub Pages deployment (docs + dashboard)#11
chrisflav merged 4 commits into
masterfrom
fix-pages-deploy

Conversation

@chrisflav

Copy link
Copy Markdown
Owner

Fixes the GitHub Pages deployment added in #10, which failed on master.

Two bugs

  1. lake: No such file or directorypages.yml installed elan after the docs step, but docgen-action's build script invokes ~/.elan/bin/lake directly. Install elan first.
  2. 409 Conflict on the github-pages artifact — docgen-action@v1 runs upload-pages-artifact on every push regardless of its deploy input (only its deploy-pages step honours the flag). So the workflow's own upload-pages-artifact was a second github-pages artifact and collided.

Fix

Since GitHub Pages allows only one deployment per repo and docgen-action insists on uploading its docs/ directory, let docgen own the single upload + deploy instead of deploying separately. The workflow now:

  1. builds the dashboard (chapter with Lean v4.32.0-rc1, Verso site with v4.31.0),
  2. drops it into docgen's output dir (docs/dashboard) and adds a landing docs/index.html,
  3. runs docgen-action (build-page: false), which builds the API docs into docs/docs and uploads + deploys the whole docs/ tree.

Resulting site: landing page at /, API docs at /docs, dashboard at /dashboard.

(docgen's build_docs.sh only does mkdir -p docs + cp … docs/docs, no rm, so the pre-placed dashboard survives.)

Before merging

This branch is set up so the site can be deployed and tested from it. Remove the temporary bits before/after merge:

  • remove fix-pages-deploy from the push: trigger in pages.yml;
  • remove the fix-pages-deploy branch from the github-pages environment's deployment-branch policies.

🤖 Generated with Claude Code

docgen-action's build script invokes `~/.elan/bin/lake`, which did not exist
because elan was installed after the docs build — install it first.

Also temporarily add `fix-pages-deploy` to the push trigger so the combined
GitHub Pages site can be deployed and tested from this branch before merging
(to be removed before merge).
docgen-action@v1 uploads the `github-pages` artifact on every push regardless of
its `deploy` input, so a second `upload-pages-artifact` collided (409). Instead
of deploying separately, build the dashboard first, drop it into docgen's `docs/`
output directory, and let docgen perform the one upload + deploy of everything
(landing page at /, API docs at /docs, dashboard at /dashboard).
The `v1` tag of docgen-action has no `deploy`/`build-page` inputs and uploads +
deploys unconditionally (and runs Jekyll whenever a `docs/` folder exists, which
failed with no Gemfile). Pin to a newer docgen revision that honours
`deploy: false` + `build-page: false`, so docgen only *builds* the API docs; we
then assemble the combined site (landing /, docs /docs, dashboard /dashboard) and
do the single upload + deploy ourselves.
Drop the `fix-pages-deploy` branch from the push trigger now that the combined
docs + dashboard deployment is validated; the `github-pages` environment
branch policy for it has been removed too.
@chrisflav
chrisflav merged commit b41fad0 into master Jun 29, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant