Skip to content

Commit

Permalink
only push to cocapod for now
Browse files Browse the repository at this point in the history
  • Loading branch information
KennyHuRadar committed Oct 3, 2024
1 parent 16a0181 commit 5a660f8
Showing 1 changed file with 0 additions and 75 deletions.
75 changes: 0 additions & 75 deletions .github/workflows/release-sdk.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,81 +22,6 @@ jobs:
- name: Checkout
uses: actions/checkout@v2

- name: Build, test, and analyze (RadarSDK)
run: xcodebuild clean build analyze test -workspace Example/Example.xcodeproj/project.xcworkspace -scheme RadarSDK -destination "platform=iOS Simulator,name=iPhone 15 Pro" | xcpretty

- name: Build archive for iPhone simulator (RadarSDK)
run: xcodebuild archive -scheme RadarSDK -archivePath "RadarSDK-iphonesimulator.xcarchive" -sdk iphonesimulator SKIP_INSTALL=NO CODE_SIGN_IDENTITY= CODE_SIGNING_REQUIRED=NO

- name: Build archive for iPhone device (RadarSDK)
run: xcodebuild archive -scheme RadarSDK -archivePath "RadarSDK-iphoneos.xcarchive" -sdk iphoneos SKIP_INSTALL=NO CODE_SIGN_IDENTITY= CODE_SIGNING_REQUIRED=NO

- name: Build archive for iPhone simulator (RadarSDKMotion)
run: cd RadarSDKMotion && xcodebuild archive -scheme RadarSDKMotion -archivePath "../RadarSDKMotion-iphonesimulator.xcarchive" -sdk iphonesimulator SKIP_INSTALL=NO CODE_SIGN_IDENTITY= CODE_SIGNING_REQUIRED=NO

- name: Build archive for iPhone device (RadarSDKMotion)
run: cd RadarSDKMotion && xcodebuild archive -scheme RadarSDKMotion -archivePath "../RadarSDKMotion-iphoneos.xcarchive" -sdk iphoneos SKIP_INSTALL=NO CODE_SIGN_IDENTITY= CODE_SIGNING_REQUIRED=NO

- name: Build archive for iPhone simulator (RadarSDKLocationPermission)
run: cd RadarSDKLocationPermission && xcodebuild archive -scheme RadarSDKLocationPermission -archivePath "../RadarSDKLocationPermission-iphonesimulator.xcarchive" -sdk iphonesimulator SKIP_INSTALL=NO CODE_SIGN_IDENTITY= CODE_SIGNING_REQUIRED=NO

- name: Build archive for iPhone device (RadarSDKLocationPermission)
run: cd RadarSDKLocationPermission && xcodebuild archive -scheme RadarSDKLocationPermission -archivePath "../RadarSDKLocationPermission-iphoneos.xcarchive" -sdk iphoneos SKIP_INSTALL=NO CODE_SIGN_IDENTITY= CODE_SIGNING_REQUIRED=NO

- name: Build XCFramework (RadarSDK)
run: xcodebuild -create-xcframework -framework RadarSDK-iphonesimulator.xcarchive/Products/Library/Frameworks/RadarSDK.framework -framework RadarSDK-iphoneos.xcarchive/Products/Library/Frameworks/RadarSDK.framework -output RadarSDK.xcframework

- name: Build XCFramework (RadarSDKMotion)
run: xcodebuild -create-xcframework -framework RadarSDKMotion-iphonesimulator.xcarchive/Products/Library/Frameworks/RadarSDKMotion.framework -framework RadarSDKMotion-iphoneos.xcarchive/Products/Library/Frameworks/RadarSDKMotion.framework -output RadarSDKMotion.xcframework

- name: Build XCFramework (RadarSDKLocationPermission)
run: xcodebuild -create-xcframework -framework RadarSDKLocationPermission-iphonesimulator.xcarchive/Products/Library/Frameworks/RadarSDKLocationPermission.framework -framework RadarSDKLocationPermission-iphoneos.xcarchive/Products/Library/Frameworks/RadarSDKLocationPermission.framework -output RadarSDKLocationPermission.xcframework

- name: Zip XCFramework (RadarSDK)
run: zip -r RadarSDK.xcframework.zip RadarSDK.xcframework -x ".*" -x "__MACOSX" -D

- name: Zip XCFramework (RadarSDKMotion)
run: zip -r RadarSDKMotion.xcframework.zip RadarSDKMotion.xcframework -x ".*" -x "__MACOSX" -D

- name: Zip XCFramework (RadarSDKLocationPermission)
run: zip -r RadarSDKLocationPermission.xcframework.zip RadarSDKLocationPermission.xcframework -x ".*" -x "__MACOSX" -D

- name: Upload XCFramework to release (RadarSDK)
uses: svenstaro/upload-release-action@v2
with:
file: RadarSDK.xcframework.zip

- name: Upload XCFramework to release (RadarSDKMotion)
uses: svenstaro/upload-release-action@v2
with:
file: RadarSDKMotion.xcframework.zip

- name: Upload XCFramework to release (RadarSDKLocationPermission)
uses: svenstaro/upload-release-action@v2
with:
file: RadarSDKLocationPermission.xcframework.zip

# get sha256 checksum of the XCFramework
- name: Get SHA256 checksum (RadarSDK)
id: checksum_radarsdk
run: echo "::set-output name=checksum::$(shasum -a 256 RadarSDK.xcframework.zip | cut -d ' ' -f 1)"

- name: Get SHA256 checksum (RadarSDKMotion)
id: checksum_radarsdkmotion
run: echo "::set-output name=checksum::$(shasum -a 256 RadarSDKMotion.xcframework.zip | cut -d ' ' -f 1)"

- name: Get SHA256 checksum (RadarSDKLocationPermission)
id: checksum_RadarSDKLocationPermission
run: echo "::set-output name=checksum::$(shasum -a 256 RadarSDKLocationPermission.xcframework.zip | cut -d ' ' -f 1)"

- name: Repository Dispatch
uses: peter-evans/repository-dispatch@v3
with:
token: ${{ secrets.SPM_REPO_KEY }}
repository: radarlabs/radar-sdk-ios-spm
event-type: update-xcframework
client-payload: '{"release": "${{ github.event.release.tag_name }}", "checksum": "${{ steps.checksum_radarsdk.outputs.checksum }}", "url": "${{ github.event.release.html_url }}", "checksum_motion": "${{ steps.checksum_radarsdkmotion.outputs.checksum }}", "checksum_locationpermissions": "${{ steps.checksum_RadarSDKLocationPermission.outputs.checksum }}"}'

- name: Deploy to Cocoapods
run: |
set -eo pipefail
Expand Down

0 comments on commit 5a660f8

Please sign in to comment.