Skip to content

ci(storybook): deploy develop to a /develop subpath alongside main - #109

Merged
Arthurk12 merged 1 commit into
bigbluebutton:developfrom
Arthurk12:ci/storybook-develop
Oct 15, 2026
Merged

Arthurk12 merged 1 commit into
bigbluebutton:developfrom
Arthurk12:ci/storybook-develop

Conversation

@Arthurk12

@Arthurk12 Arthurk12 commented Oct 15, 2026 •

Copy link
Copy Markdown
Member

What does this PR do?

  • Triggers the Storybook deploy on pushes to develop as well as main.
  • Deploys develop into a develop/ subdirectory of gh-pages, keeping main at the root:
    • main → https://bigbluebutton.github.io/bbb-ui-components-react/
    • develop → https://bigbluebutton.github.io/bbb-ui-components-react/develop/
  • Before the main deploy, copies the current develop/ from gh-pages into the build output. The main deploy uses keep_files: false, which cleans the whole branch root, so without this copy it would remove develop/. If gh-pages doesn't exist yet (new repository or fork), the copy is skipped and the deploy creates the branch.
  • Runs the job in a shared concurrency group with queue: max, so main and develop runs, which both push to gh-pages, wait in line instead of rejecting each other's push. With the default single pending slot, a newer pending run would cancel an older one.
  • Skips the job when it is dispatched manually from any branch other than main or develop, so a feature branch can never overwrite the published root.

Closes Issue(s)

Closes none

Motivation

Only main is published, so changes merged into develop can't be browsed or reviewed in Storybook until they are released. Publishing both gives one Storybook for what is released and another for what is coming next.

More::

  • The main deploy only starts preserving develop/ once this change reaches main. Until then, every main deploy wipes the develop Storybook, and the next push to develop brings it back.
  • The develop deploy cleans only its own subdirectory (peaceiris/actions-gh-pages runs git rm from inside destination_dir).
  • Storybook builds use relative asset paths, so it works from the subpath without any config change.
  • queue is a recent concurrency option. The docs' example sets it at workflow level; here it is set on the job, which the docs describe but which hasn't been run yet. The first push to develop after merging confirms it.
  • Not run on GitHub Actions yet. actionlint 1.7.12 passes except for unexpected key "queue", because it doesn't know that option yet. The step that preserves develop/ was simulated locally.

Only main is published to GitHub Pages, so changes merged into develop
can't be browsed or reviewed in Storybook until they are released.

Trigger the deploy on pushes to develop as well, publishing it into a
develop/ subdirectory of gh-pages while main stays at the root:

- Before the main deploy, copy the current develop/ from gh-pages into
  the build output. The main deploy uses keep_files: false, which
  cleans the whole branch root, so without this copy it would remove
  develop/. If gh-pages doesn't exist yet (new repository or fork),
  skip the copy and let the deploy create the branch.
- Run the job in a shared concurrency group with queue: max, so main
  and develop runs, which both push to gh-pages, wait in line instead
  of rejecting each other's push. With the default single pending
  slot, a newer pending run would cancel an older one.
- Skip the job when it is dispatched manually from any branch other
  than main or develop, so a feature branch can never overwrite the
  published root.

Deploying develop to a separate branch was considered and discarded:
GitHub Pages serves a single site per repository, so another branch
would not be published.
@Arthurk12
Arthurk12 force-pushed the ci/storybook-develop branch from ada5f7b to 276290d Compare October 15, 2026 17:43
@Arthurk12
Arthurk12 merged commit 5450ef1 into bigbluebutton:develop Oct 15, 2026
2 checks passed
@Arthurk12
Arthurk12 deleted the ci/storybook-develop branch October 15, 2026 17:48
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