@@ -139,7 +139,7 @@ jobs:
139139 codesign --sign "${{ secrets.APPLE_TEAM_ID }}" --timestamp --options runtime dist/vector.xcframework # Then sign the xcframework wrapper
140140 ditto -c -k --keepParent dist/vector.xcframework dist/vector.xcframework.zip
141141 xcrun notarytool submit dist/vector.xcframework.zip --apple-id "${{ secrets.APPLE_ID }}" --password "${{ secrets.APPLE_PASSWORD }}" --team-id "${{ secrets.APPLE_TEAM_ID }}" --wait
142- rm dist/vector.xcframework.zip
142+ rm -rf dist/vector.xcframework
143143
144144 - name : cleanup keychain for codesign
145145 if : matrix.os == 'macos-15'
@@ -224,7 +224,11 @@ jobs:
224224 if [[ "$name" != "vector-apple-xcframework" && "$name" != "vector-android-aar" ]]; then
225225 tar -czf "${name}-${VERSION}.tar.gz" -C "$folder" .
226226 fi
227- if [[ "$name" != "vector-android-aar" ]]; then
227+ if [[ "$name" == "vector-apple-xcframework" ]]; then
228+ # Use the ditto-created zip that preserves macOS symlinks and extract for other steps
229+ cp "$folder/vector.xcframework.zip" "${name}-${VERSION}.zip"
230+ unzip -q "$folder/vector.xcframework.zip" -d "$folder/"
231+ elif [[ "$name" != "vector-android-aar" ]]; then
228232 (cd "$folder" && zip -rq "../../${name}-${VERSION}.zip" .)
229233 else
230234 cp "$folder"/*.aar "${name}-${VERSION}.aar"
@@ -344,6 +348,23 @@ jobs:
344348 echo " Platform packages: 7"
345349 echo "━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━"
346350
351+ - name : update Package.swift checksum and version
352+ if : steps.tag.outputs.version != ''
353+ run : |
354+ VERSION=${{ steps.tag.outputs.version }}
355+ ZIP="vector-apple-xcframework-${VERSION}.zip"
356+ if [ -f "$ZIP" ]; then
357+ CHECKSUM=$(swift package compute-checksum "$ZIP")
358+ URL="https://github.com/sqliteai/sqlite-vector/releases/download/${VERSION}/${ZIP}"
359+ sed -i "s|url: \".*apple-xcframework.*\"|url: \"${URL}\"|" Package.swift
360+ sed -i "s|checksum: \".*\"|checksum: \"${CHECKSUM}\"|" Package.swift
361+ git config --global user.email "$GITHUB_ACTOR@users.noreply.github.com"
362+ git config --global user.name "$GITHUB_ACTOR"
363+ git add Package.swift
364+ git commit -m "Update Package.swift checksum for ${VERSION} [skip ci]" || true
365+ git push origin main || true
366+ fi
367+
347368 - uses : softprops/action-gh-release@v2.2.1
348369 if : steps.tag.outputs.version != ''
349370 with :
0 commit comments