Repository navigation
ci: add package selection inputs to publish preview workflow - #11682
Merged
Merged
Conversation
Add `packages` and `only-changed-packages` inputs to the publish preview workflow and pass them through to the reusable workflow. Callers can now publish preview builds for a chosen set of packages, or only for the packages changed compared to the base branch, instead of always publishing everything.
Contributor
🛑 Files requiring codeowner reviewTo merge this PR, you'll need to get approvals from the following owners. @MetaMask/core-platform (1 file)
|
Mrtenz
commented
Nov 20, 2026
| description: 'Only publish packages changed compared to the base branch. Mutually exclusive with "packages".' | ||
| required: false | ||
| type: boolean | ||
| default: true |
Member
Author
There was a problem hiding this comment.
Downside of having this enabled by default is that you need to remember to uncheck it when filling out "packages". Wondering if we should disable it by default?
Contributor
There was a problem hiding this comment.
I’d keep it enabled and check back next week, once teams have used it a few times, to see whether they’re using it as intended.
Mrtenz
marked this pull request as ready for review
November 20, 2026 11:35
Mrtenz
temporarily deployed
to
default-branch
November 20, 2026 11:35 — with
GitHub Actions
Inactive
cryptodev-2s
approved these changes
Nov 20, 2026
Qkin-Keystone
pushed a commit
to KeystoneHQ/accounts
that referenced
this pull request
Nov 24, 2026
The "Publish a preview build" workflow runs when someone comments `@metamaskbot publish-preview`, and it publishes with the long-lived `PUBLISH_PREVIEW_NPM_TOKEN` secret. This PR moves it to NPM trusted publishing (OIDC), which `MetaMask/core` already uses. - `publish-preview.yml` now runs manually through `workflow_dispatch` and calls the `publish-preview-oidc.yml` reusable workflow from `MetaMask/github-tools`. It takes a pull request number or a branch. It can publish all packages, a given list, or only the packages that changed. Publishing goes through the `npm-preview` environment, so we no longer need the NPM token secret. - `publish-preview-comment.yml` is new. If someone posts the old `@metamaskbot publish-preview` comment, it replies with a link to the new workflow and the PR number to enter. ## References - MetaMask/core#11534 - MetaMask/core#11682
This was referenced Nov 24, 2026
This branch was previously deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Explanation
The publish preview workflow currently publishes preview builds for every package in the monorepo. This adds two inputs to the workflow and passes them through to the reusable workflow:
packages: a comma-separated list of packages to publish (e.g.,@metamask/network-controller, permission-controller). If left empty, all packages are published.only-changed-packages: when enabled, publishes only the packages that changed relative to the base branch. Defaults totrue.The two inputs can't be used together.
References
Checklist
Note
Low Risk
Workflow-only change with no runtime or data-handling impact; risk is limited to CI preview publish scope and depends on the external reusable workflow behaving as documented.
Overview
Extends the manual publish preview workflow (
publish-preview.yml) so runs no longer have to publish the entire monorepo by default.Two new
workflow_dispatchinputs are wired through toMetaMask/github-tools’spublish-preview-oidcreusable workflow:packages(optional comma-separated allowlist; empty means all packages) andonly-changed-packages(defaults totrue, limits publishes to packages changed vs the base branch). The inputs are documented as mutually exclusive.This is CI configuration only; behavior depends on the shared workflow in github-tools (referenced in the PR).
Reviewed by Cursor Bugbot for commit eab7370. Bugbot is set up for automated code reviews on this repo. Configure here.