Skip to content

Build: Limit bench-packages to next/main as base branches #31544

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: next
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions scripts/bench/bench-packages.ts
Original file line number Diff line number Diff line change
Expand Up @@ -404,6 +404,11 @@ const run = async () => {
) as PackageName[];
const options = program.opts<{ pullRequest?: number; baseBranch?: string; upload?: boolean }>();

if (options.baseBranch !== 'main' && options.baseBranch !== 'next') {
console.warn('Base branch must be main or next, skipping...');
process.exit(0);
}
Comment on lines +407 to +410
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

style: Consider adding this check before the GCP credentials validation to fail faster


if (options.upload || options.baseBranch) {
if (!GCP_CREDENTIALS.project_id) {
throw new Error(
Expand Down
Loading