Skip to content

Workaround the 32bit target on Xcode 15.2 #116

Workaround the 32bit target on Xcode 15.2

Workaround the 32bit target on Xcode 15.2 #116

Workflow file for this run

name: "SDWebImageSwiftUI CI"
on:
push:
branches:
- master
pull_request:
branches:
- '*'
permissions:
contents: read
jobs:
Pods:
name: Cocoapods Lint
runs-on: macos-13
env:
DEVELOPER_DIR: /Applications/Xcode_14.1.app
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Install Cocoapods
run: gem install cocoapods --no-document --quiet
- name: Install Xcpretty
run: gem install xcpretty --no-document --quiet
- name: Run SDWebImageSwiftUI podspec lint
run: |
set -o pipefail
pod lib lint SDWebImageSwiftUI.podspec --allow-warnings --skip-tests
Demo:
name: Run Demo
runs-on: macos-13
env:
DEVELOPER_DIR: /Applications/Xcode_14.1.app
WORKSPACE_NAME: SDWebImageSwiftUI.xcworkspace
OSXSCHEME: SDWebImageSwiftUIDemo-macOS
iOSSCHEME: SDWebImageSwiftUIDemo
TVSCHEME: SDWebImageSwiftUIDemo-tvOS
WATCHSCHEME: SDWebImageSwiftUIDemo-watchOS WatchKit App
strategy:
matrix:
iosDestination: ["platform=iOS Simulator,name=iPhone 14 Pro"]
tvOSDestination: ["platform=tvOS Simulator,name=Apple TV"]
watchOSDestination: ["platform=watchOS Simulator,name=Apple Watch Series 8 (45mm)"]
macOSDestination: ["platform=macOS"]
macCatalystDestination: ["platform=macOS,variant=Mac Catalyst"]
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Clean DerivedData
run: |
rm -rf ~/Library/Developer/Xcode/DerivedData/
mkdir DerivedData
- name: Install Cocoapods
run: gem install cocoapods --no-document --quiet
- name: Install Xcpretty
run: gem install xcpretty --no-document --quiet
- name: Pod Update
run: pod repo update --silent
- name: Pod Install
run: pod install
- name: Run demo for OSX
run: |
set -o pipefail
xcodebuild build -workspace "${{ env.WORKSPACE_NAME }}" -scheme "${{ env.OSXSCHEME }}" -destination "${{ matrix.macOSDestination }}" -configuration Debug CODE_SIGNING_ALLOWED=NO | xcpretty -c
- name: Run demo for iOS
run: |
set -o pipefail
xcodebuild build -workspace "${{ env.WORKSPACE_NAME }}" -scheme "${{ env.iOSSCHEME }}" -destination "${{ matrix.iosDestination }}" -configuration Debug CODE_SIGNING_ALLOWED=NO | xcpretty -c
- name: Run demo for TV
run: |
set -o pipefail
xcodebuild build -workspace "${{ env.WORKSPACE_NAME }}" -scheme "${{ env.TVSCHEME }}" -destination "${{ matrix.tvOSDestination }}" -configuration Debug CODE_SIGNING_ALLOWED=NO | xcpretty -c
- name: Run demo for Watch
run: |
set -o pipefail
xcodebuild build -workspace "${{ env.WORKSPACE_NAME }}" -scheme "${{ env.WATCHSCHEME }}" -destination "${{ matrix.watchOSDestination }}" -configuration Debug CODE_SIGNING_ALLOWED=NO | xcpretty -c
Test:
name: Unit Test
runs-on: macos-13
env:
DEVELOPER_DIR: /Applications/Xcode_14.1.app
WORKSPACE_NAME: SDWebImageSwiftUI.xcworkspace
OSXSCHEME: SDWebImageSwiftUITests macOS
iOSSCHEME: SDWebImageSwiftUITests
TVSCHEME: SDWebImageSwiftUITests tvOS
strategy:
matrix:
iosDestination: ["platform=iOS Simulator,name=iPhone 14 Pro"]
macOSDestination: ["platform=macOS"]
tvOSDestination: ["platform=tvOS Simulator,name=Apple TV"]
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Clean DerivedData
run: |
rm -rf ~/Library/Developer/Xcode/DerivedData/
mkdir DerivedData
- name: Install Cocoapods
run: gem install cocoapods --no-document --quiet
- name: Install Xcpretty
run: gem install xcpretty --no-document --quiet
- name: Pod Update
run: pod repo update --silent
- name: Pod Install
run: pod install
- name: Test - ${{ matrix.iosDestination }}
run: |
set -o pipefail
xcodebuild test -workspace "${{ env.WORKSPACE_NAME }}" -scheme "${{ env.iOSSCHEME }}" -destination "${{ matrix.iosDestination }}" -configuration Debug CODE_SIGNING_ALLOWED=NO | xcpretty -c
mv ~/Library/Developer/Xcode/DerivedData/ ./DerivedData/iOS
- name: Test - ${{ matrix.macOSDestination }}
run: |
set -o pipefail
xcodebuild test -workspace "${{ env.WORKSPACE_NAME }}" -scheme "${{ env.OSXSCHEME }}" -destination "${{ matrix.macOSDestination }}" -configuration Debug CODE_SIGNING_ALLOWED=NO
mv ~/Library/Developer/Xcode/DerivedData/ ./DerivedData/macOS
- name: Test - ${{ matrix.tvOSDestination }}
run: |
set -o pipefail
xcodebuild test -workspace "${{ env.WORKSPACE_NAME }}" -scheme "${{ env.TVSCHEME }}" -destination "${{ matrix.tvOSDestination }}" -configuration Debug CODE_SIGNING_ALLOWED=NO | xcpretty -c
mv ~/Library/Developer/Xcode/DerivedData/ ./DerivedData/tvOS
- name: Code Coverage
run: |
set -o pipefail
export PATH="/usr/local/opt/curl/bin:$PATH"
curl --version
bash <(curl -s https://codecov.io/bash) -D './DerivedData/macOS' -J '^SDWebImageSwiftUI$' -c -X gcov -F macos
bash <(curl -s https://codecov.io/bash) -D './DerivedData/iOS' -J '^SDWebImageSwiftUI$' -c -X gcov -F ios
bash <(curl -s https://codecov.io/bash) -D './DerivedData/tvOS' -J '^SDWebImageSwiftUI$' -c -X gcov -F tvos
Build:
name: Build Library
runs-on: macos-13
env:
DEVELOPER_DIR: /Applications/Xcode_14.1.app
PROJECT_NAME: SDWebImageSwiftUI.xcodeproj
OSXSCHEME: SDWebImageSwiftUI macOS
iOSSCHEME: SDWebImageSwiftUI
TVSCHEME: SDWebImageSwiftUI tvOS
WATCHSCHEME: SDWebImageSwiftUI watchOS
steps:
- name: Checkout
uses: actions/checkout@v2
- name: Build the SwiftPM
run: |
set -o pipefail
swift build
rm -rf ~/.build
- name: Install Carthage
run: brew install carthage
- name: Carthage Update
run: ./carthage.sh update --platform "iOS, tvOS, macOS, watchOS"
- name: Build as dynamic frameworks
run: |
set -o pipefail
xcodebuild build -project "${{ env.PROJECT_NAME }}" -scheme "${{ env.OSXSCHEME }}" -sdk macosx -configuration Release | xcpretty -c
xcodebuild build -project "${{ env.PROJECT_NAME }}" -scheme "${{ env.iOSSCHEME }}" -sdk iphoneos -configuration Release | xcpretty -c
xcodebuild build -project "${{ env.PROJECT_NAME }}" -scheme "${{ env.TVSCHEME }}" -sdk appletvos -configuration Release | xcpretty -c
xcodebuild build -project "${{ env.PROJECT_NAME }}" -scheme "${{ env.WATCHSCHEME }}" -sdk watchos -configuration Release | xcpretty -c