Skip to content

ci(docs): stage 2nd-gen docs on merge, gate prod publish behind #gen2-publish - #6637

Open
blunteshwar wants to merge 2 commits into
release-strategyfrom
SWC-2487
Open

ci(docs): stage 2nd-gen docs on merge, gate prod publish behind #gen2-publish#6637
blunteshwar wants to merge 2 commits into
release-strategyfrom
SWC-2487

Conversation

@blunteshwar

@blunteshwar blunteshwar commented Aug 19, 2026

Copy link
Copy Markdown
Contributor

Description

Splits the 2nd-gen documentation deploy into two targets so the public site can stay in sync with releases instead of updating on every merge:

  • Staging — every push to main (non-1st-gen changes) syncs to $web/docs-staging/ (https://swcpreviews.z13.web.core.windows.net/docs-staging/). This preserves the always-latest environment we have today.
  • Production$web/docs/ (mapped to spectrum-web-components.adobe.com) now deploys only on a manual workflow_dispatch or a push to main whose commit message contains #gen2-publish.

The keyword is #gen2-publish rather than #publish on purpose: the 1st-gen publish-docs-site.yml matches on the #publish substring, so a shared keyword would couple the two sites. #gen2-publish does not contain #publish, keeping them independent.

publish-2nd-gen.yml's Version PR title now includes #gen2-publish too (chore: release 2nd-gen packages (beta) #gen2-publish) — the actual release event is the squash-merge of that PR, and squash merges use the PR title as the merge commit message on main (confirmed against this repo's own release-commit history, e.g. chore: release packages #publish (#6470)). Without this, the keyword would only ever appear on a manual workflow_dispatch, and the production docs site would never sync with a real gen2 release.

Motivation and context

We're moving into pre-release/beta publishing and want the public 2nd-gen docs site to update in sync with announced releases, not on every merge. Staging keeps tracking main for day-to-day validation.

Rebased onto the current release-strategy base (post gen1/gen2 changesets split in #6607) — the docs-deploy workflow itself is orthogonal to package publishing, but its production trigger needed to be wired to the actual release event under the new Version PR flow.

Related issue(s)

  • SWC-2487

Screenshots (if appropriate)

N/A — CI/documentation-deploy change only; no component or runtime UI is modified.

Author's checklist

  • I have read the CONTRIBUTING and PULL_REQUESTS documents.
  • I have reviewed at the Accessibility Practices for this feature — N/A, no UI surface.
  • I have added automated tests to cover my changes — N/A, workflow YAML isn't unit-testable in this repo; validated via manual review of the if: gating logic and this repo's historical squash-merge commit messages.
  • I have included a well-written changeset if my change needs to be published — N/A, CI/docs-only, no published package changed.
  • I have included updated documentation if my change required it (CONTRIBUTOR-DOCS/01_contributor-guides/06_releasing-swc.md).

Reviewer's checklist

  • Includes a GitHub Issue with appropriate flag or Jira ticket number without a link
  • Automated tests cover all use cases and follow best practices for writing
  • Validated on all supported browsers
  • All VRTs are approved before the author can update Golden Hash

Manual review test cases

  • Staging deploys on merge

    1. Merge a non-1st-gen change to main.
    2. Confirm Publish 2nd-Gen Documentation runs the "Deploy to staging" step and skips "Deploy to production".
    3. Verify https://swcpreviews.z13.web.core.windows.net/docs-staging/ reflects the change.
  • Production deploys on a real gen2 release

    1. Merge the 2nd-gen Version PR (chore: release 2nd-gen packages (beta) #gen2-publish) opened by publish-2nd-gen.yml.
    2. Confirm the resulting squash-merge commit message on main contains #gen2-publish.
    3. Confirm both "Deploy to staging" and "Deploy to production" run.
    4. Verify spectrum-web-components.adobe.com reflects the change.
  • Production deploys on manual dispatch

    1. Run Publish 2nd-Gen Documentation via workflow_dispatch.
    2. Confirm both steps run regardless of the latest commit message.
  • No cross-trigger with 1st-gen

    1. Confirm a #gen2-publish commit does not trigger Publish Documentation Site (1st-gen).

Device review

  • Did it pass in Desktop? (N/A — no UI)
  • Did it pass in (emulated) Mobile? (N/A — no UI)
  • Did it pass in (emulated) iPad? (N/A — no UI)

Accessibility testing checklist

N/A — this PR only changes CI/documentation-deploy configuration; no component, page, or interactive surface is affected. No keyboard or screen reader testing applies.

  • Keyboard (required — document steps below)

    1. N/A — no focusable UI is added or changed by this workflow/docs update.
  • Screen reader (required — document steps below)

    1. N/A — no roles, names, or announcements are affected by this workflow/docs update.

@blunteshwar
blunteshwar requested a review from a team as a code owner August 19, 2026 05:52
@changeset-bot

changeset-bot Bot commented Aug 19, 2026

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: 1ada46e

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@blunteshwar blunteshwar added Status:Ready for review PR ready for review or re-review. do-not-merge NO MERGE-Y! skip_vrt Skip VRT build; mark UI Tests green without running Chromatic labels Aug 19, 2026
@github-actions

Copy link
Copy Markdown
Contributor

📚 Branch Preview Links

🔍 Gen1 Visual Regression Test Results

When a visual regression test fails (or has previously failed while working on this branch), its results can be found in the following URLs:

Deployed to Azure Blob Storage: pr-6637

If the changes are expected, update the current_golden_images_cache hash in the circleci config to accept the new images. Instructions are included in that file.
If the changes are unexpected, you can investigate the cause of the differences and update the code accordingly.

…-publish

Splits the 2nd-gen docs deploy into two targets so the public site stays in
sync with releases instead of updating on every merge: every push to main
now syncs to $web/docs-staging/, while $web/docs/ (spectrum-web-components.
adobe.com) deploys only on a manual workflow_dispatch or a push whose
commit message contains #gen2-publish. The keyword avoids the #publish
substring so it doesn't also trigger the Gen1 publish-docs-site workflow.

Revives the work from #6507 (closed, unmerged) now that gen2 is moving
into pre-release/beta publishing.
@blunteshwar blunteshwar changed the title [DO-NOT-MERGE] ci(docs): stage 2nd-gen docs on merge, gate prod publish behind #gen2-publish ci(docs): stage 2nd-gen docs on merge, gate prod publish behind #gen2-publish Aug 19, 2026
@blunteshwar blunteshwar removed the do-not-merge NO MERGE-Y! label Aug 19, 2026
…docs trigger

publish-2ndgen-docs.yml's production deploy step gates on the main push's
commit message containing #gen2-publish, but that push is the squash-merge
of the 2nd-gen Version PR, whose title was 'chore: release 2nd-gen packages
(beta)' - no #gen2-publish substring. Squash merges use the PR title as the
merge commit message (confirmed against this repo's own release-commit
history), so the actual release event would never have carried the keyword
and prod docs would silently never sync with a real gen2 release.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

skip_vrt Skip VRT build; mark UI Tests green without running Chromatic Status:Ready for review PR ready for review or re-review.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant