Skip to content
Closed
Show file tree
Hide file tree
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
13 changes: 13 additions & 0 deletions .github/workflows/changelog-preview.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
name: Changelog Preview
on:
pull_request:
types:
- opened
- synchronize
- reopened
- edited
- labeled
jobs:
changelog-preview:
uses: getsentry/craft/.github/workflows/changelog-preview.yml@v2
secrets: inherit
66 changes: 24 additions & 42 deletions .github/workflows/release-upload-xcframework.yml
Original file line number Diff line number Diff line change
@@ -1,47 +1,29 @@
name: Upload XCFrameworks
on:
push:
branches:
- release/**

workflow_dispatch:
inputs:
version:
description: Version to release (or "auto")
required: false
jobs:
# Craft uses the Git commit hash to query GitHub Actions for artifacts
# uploaded in a workflow run associated with that commit.
#
# To support this, we download the XCFramework already built and uploaded
# in release.yml (triggered via workflow_dispatch), and reupload it here.
# This associates it with the new commit in the release branch, which is
# created by getsentry/action-prepare-release in release.yml.
#
# This is necessary because Swift Package Manager requires a checksum for
# XCFrameworks, creating a chicken-and-egg problem: we need the XCFramework
# to generate the checksum, but we also need the checksum to update Package.swift.
#
# The sequence is:
# 1. Build the XCFrameworks in release.yml.
# 2. getsentry/action-prepare-release updates Package.swift with the checksum.
# 3. Upload the XCFrameworks again here so Craft can find it by commit.
upload-xcframeworks:
release:
runs-on: ubuntu-latest
name: Release a new version
steps:
- uses: actions/checkout@v6

- name: Get Release workflow run ID
run: echo "FRAMEWORK_RUN_ID=$(./scripts/xcframework-generated-run.sh)" >> $GITHUB_ENV

- uses: actions/download-artifact@v7
with:
name: xcframeworks.zip
path: XCFrameworkBuildPath/
github-token: ${{ secrets.GITHUB_TOKEN }}
run-id: ${{ env.FRAMEWORK_RUN_ID }}

- name: Archive XCFrameworks for Craft
uses: actions/upload-artifact@v6
with:
# Craft uses the git commit hash of the release branch to download the release artifacts.
name: ${{ github.sha }}
if-no-files-found: error
overwrite: true
path: |
${{github.workspace}}/XCFrameworkBuildPath/*.zip
- name: Get auth token
id: token
uses: actions/create-github-app-token@v1
with:
app-id: ${{ vars.SENTRY_RELEASE_BOT_CLIENT_ID }}
private-key: ${{ secrets.SENTRY_RELEASE_BOT_PRIVATE_KEY }}
- uses: actions/checkout@v4
with:
token: ${{ steps.token.outputs.token }}
fetch-depth: 0
- name: Prepare release
uses: getsentry/craft@v2
env:
GITHUB_TOKEN: ${{ steps.token.outputs.token }}
with:
version: ${{ inputs.version }}
path: '|'
Copy link

Choose a reason for hiding this comment

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

XCFramework artifact handling removed from upload workflow

High Severity

The workflow previously triggered on push to release/** branches and handled XCFramework artifact re-uploading to associate them with the release branch commit (needed for Craft to find artifacts by commit hash). The old comments explained this solves a chicken-and-egg problem with Swift Package Manager checksums. The new workflow removes both the push trigger and all artifact handling, meaning Craft will not find the XCFramework artifacts when preparing the release.

Fix in Cursor Fix in Web

Loading
Loading