Repository navigation
Conversation
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
|
| always() && !cancelled() && ( | ||
| needs.release.outputs.published == 'true' || | ||
| (github.event_name == 'workflow_dispatch' && inputs.version == '') || | ||
| (github.event_name == 'release' && |
There was a problem hiding this comment.
Release events run with a tag GITHUB_REF, but this repository’s github-pages environment currently permits only the main branch (in the GitHub configuration). I think this means the job would be rejected before version promotion or deployment.
Could we permit the intended web release tags in the environment policy, or dispatch the docs workflow on main instead? I think I have a slight preference for dispatching on main, just to keep everything strongly tied to it.
Overview
Automatically promote stable
@contentauth/c2pa-webreleases in the versioned API documentation.Changes
publishedPackagesexplicitly inside the existingpublish-docsjob. Changesets usesGITHUB_TOKENto create releases, so another release-published workflow cannot be relied upon. Separately published stable web release events are also supported without triggering package publishing.api-docs/web-versions.jsondirectly tomainwhen changed, then build and deploy the existing complete site from that same checkout. Push/verification failures stop deployment; reruns avoid empty commits. No tags are modified.Activation caveat: repository rules/branch protection must allow the
GITHUB_TOKENbot to make this direct index update. Currentmainprotection requires one review and code-owner review; no bypass permission was changed or assumed. Without a suitable bot exception, the push fails visibly before deployment. Only this implementation feature branch was pushed; no production release automation was run.Testing
pnpm test:docs: 32 tests passed, including exact prepend/promote/deduplicate, metadata preservation, byte-identical no-op, prerelease/draft/package exclusion and expression-level release/manual/Changesets routing.pnpm ci:docs:releases: both configured node/web versioned sites built successfully against public npm.0.16.0release promoted; checked the default page, all retained release pages and their exact selector metadata. Checked-in indexes were not changed by validation.git diff --checkpassed. Hosted Actions deployment and real protected-branch bot writes were not executed.Cross-package drift check
If this PR touches Settings/Context, Reader/Builder input validation, or signer/HTTP logic in one package:
c2pa-utilitiesalready owns this logic, and changed it there instead of adding a package-local copy.N/A: documentation/release automation only; shared package-neutral tooling is reused.