Skip to content

Commit

Permalink
workflow: fix release script in actions
Browse files Browse the repository at this point in the history
  • Loading branch information
yyx990803 committed Aug 8, 2024
1 parent c6841bd commit e333312
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions scripts/release.js
Original file line number Diff line number Diff line change
Expand Up @@ -499,15 +499,9 @@ async function publishPackages(version) {
if (isDryRun) {
additionalPublishFlags.push('--dry-run')
}
if (isDryRun || skipGit) {
if (isDryRun || skipGit || process.env.CI) {
additionalPublishFlags.push('--no-git-checks')
}
// bypass the pnpm --publish-branch restriction which isn't too useful to us
// otherwise it leads to a prompt and blocks the release script
const branch = await getBranch()
if (branch !== 'main') {
additionalPublishFlags.push('--publish-branch', branch)
}
// add provenance metadata when releasing from CI
// canary release commits are not pushed therefore we don't need to add provenance
if (process.env.CI && !isCanary) {
Expand Down

0 comments on commit e333312

Please sign in to comment.