Skip to content

Commit

Permalink
fix(ci): fix build with xcodebuild
Browse files Browse the repository at this point in the history
Force to download iOS platform. It does not seem to be present on all machines
  • Loading branch information
ThibaultBee committed Jan 29, 2025
1 parent 79132e4 commit 9423b60
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 8 deletions.
16 changes: 10 additions & 6 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ on:
jobs:
find_schemes:
name: Find xcode schemes
runs-on: macos-14
runs-on: macos-latest
outputs:
schemes: ${{ steps.getSchemes.outputs.schemes}}
steps:
Expand All @@ -23,7 +23,7 @@ jobs:
echo "schemes=$SCHEMES" >> $GITHUB_OUTPUT
swift_build:
name: Build with swift
runs-on: macos-14
runs-on: macos-latest
steps:
- name: Checkout
uses: actions/checkout@v4
Expand All @@ -36,7 +36,7 @@ jobs:
xcode_build:
name: Build with xcode
needs: find_schemes
runs-on: macos-14
runs-on: macos-latest
strategy:
matrix: ${{ fromJson(needs.find_schemes.outputs.schemes) }}
steps:
Expand All @@ -47,10 +47,12 @@ jobs:
with:
xcode-version: latest-stable
- name: Build ${{matrix.scheme}}
run: xcodebuild clean build -project ApiVideoLiveStream.xcodeproj -scheme "${{matrix.scheme}}" -sdk iphoneos CODE_SIGNING_ALLOWED=NO
run: |
xcodebuild -downloadPlatform iOS
xcodebuild clean build -project ApiVideoLiveStream.xcodeproj -scheme "${{matrix.scheme}}" -sdk iphoneos CODE_SIGNING_ALLOWED=NO
verify:
name: Verify package sanity
runs-on: macos-14
runs-on: macos-latest
steps:
- name: Checkout
uses: actions/checkout@v4
Expand All @@ -59,7 +61,9 @@ jobs:
with:
xcode-version: latest-stable
- name: Verify cocoapods
run: pod lib lint --allow-warnings
run: |
xcodebuild -downloadPlatform iOS
pod lib lint --allow-warnings
- name: Install swiftlint
run: brew install swiftlint
- name: Execute swiftlint
Expand Down
6 changes: 4 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,14 @@ on:
types: [published]
jobs:
deploy:
runs-on: macos-14
runs-on: macos-latest
steps:
- uses: actions/checkout@v4
- name: Install Cocoapods
run: gem install cocoapods
- name: Deploy to Cocoapods
run: pod trunk push --allow-warnings
run: |
xcodebuild -downloadPlatform iOS
pod trunk push --allow-warnings
env:
COCOAPODS_TRUNK_TOKEN: ${{ secrets.COCOAPODS_TRUNK_TOKEN }}

0 comments on commit 9423b60

Please sign in to comment.