-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
ci(release): Switch from action-prepare-release to Craft #18763
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
base: develop
Are you sure you want to change the base?
Conversation
This PR migrates from the deprecated action-prepare-release to the new Craft GitHub Actions (reusable workflow or composite action). Changes: - Migrate .github/workflows/release.yml to Craft reusable workflow
f89e6b1 to
b9ae430
Compare
Semver Impact of This PR🟢 Patch (bug fixes) 📋 Changelog PreviewThis is how your changes will appear in the changelog. New Features ✨Core
Other
Bug Fixes 🐛Browser
Core
Next
Nextjs
Other
Documentation 📚
Build / dependencies / internal 🔧Core
Deps
NextjsOther
Other
🤖 This preview updates automatically when you update the PR. |
node-overhead report 🧳Note: This is a synthetic benchmark with a minimal express app and does not necessarily reflect the real-world performance impact in an application.
|
The previous migration incorrectly removed the GitHub App token authentication step. This commit restores it by switching to the composite action pattern which preserves the auth flow.
The previous migration incorrectly removed the GitHub App token authentication step. This commit restores it by switching to the composite action pattern which preserves the auth flow.
.github/workflows/auto-release.yml
Outdated
| on: | ||
| pull_request: | ||
| types: | ||
| - closed | ||
| branches: | ||
| - master | ||
|
|
||
| # This workflow tirggers a release when merging a branch with the pattern `prepare-release/VERSION` into master. | ||
| workflow_dispatch: | ||
| inputs: | ||
| version: | ||
| description: Version to release (or "auto") | ||
| required: false | ||
| force: | ||
| description: Force a release even when there are release-blockers |
This comment was marked as outdated.
This comment was marked as outdated.
Sorry, something went wrong.
.github/workflows/auto-release.yml
Outdated
| on: | ||
| pull_request: | ||
| types: | ||
| - closed | ||
| branches: | ||
| - master | ||
| workflow_dispatch: | ||
| inputs: | ||
| version: | ||
| description: Version to release (or "auto") | ||
| required: false | ||
| force: | ||
| description: Force a release even when there are release-blockers | ||
| required: false | ||
| merge_target: |
This comment was marked as outdated.
This comment was marked as outdated.
Sorry, something went wrong.
| - name: Prepare release | ||
| uses: getsentry/craft@39ee616a6a58dc64797feecb145d66770492b66c # v2 | ||
| env: | ||
| GITHUB_TOKEN: ${{ steps.token.outputs.token }} | ||
| with: | ||
| version: ${{ inputs.version }} | ||
| force: ${{ inputs.force }} | ||
| merge_target: ${{ inputs.merge_target }} | ||
| craft_config_from_merge_target: 'true' |
This comment was marked as outdated.
This comment was marked as outdated.
Sorry, something went wrong.
| required: false | ||
| merge_target: | ||
| description: Target branch to merge into. Uses the default branch as a fallback (optional) | ||
| description: Target branch to merge into |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removed default value for merge_target input
Medium Severity
The merge_target input previously had default: master but this was removed. When users trigger the release workflow without specifying a merge_target, an empty value will be passed to the Craft action via ${{ inputs.merge_target }}. In contrast, auto-release.yml explicitly passes merge_target: master. If Craft doesn't handle empty merge_target values gracefully, this could cause the release workflow to fail or behave unexpectedly.
| - name: Get auth token | ||
| id: token | ||
| uses: actions/create-github-app-token@29824e69f54612133e76f7eaac726eef6c875baf # v2.2.1 | ||
| uses: actions/create-github-app-token@29824e69f54612133e76f7eaac726eef6c875baf # v2 # v2 # v1 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Duplicate version comments from repeated tool runs
Low Severity
Multiple workflow files contain action references with accumulated version comments like # v2 # v2 # v1 and # v6 # v6 # v4. These appear to be artifacts from running a version pinning tool multiple times. The comments are inconsistent and confusing - for example, actions/checkout@...# v6 # v6 # v4 has conflicting version indicators. While the commit hash determines the actual version used, these accumulated comments could mislead maintainers about which version is pinned.
Summary
This PR migrates from the deprecated
action-prepare-releaseto the new Craft GitHub Actions.Changes
.github/workflows/auto-release.ymlto Craft reusable workflowDocumentation
See https://getsentry.github.io/craft/github-actions/ for more information.
Closes #18765 (added automatically)