forked from jellyfin/Swiftfin
-
Notifications
You must be signed in to change notification settings - Fork 0
62 lines (52 loc) · 1.6 KB
/
ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
name: "Build 🔨"
on:
push:
branches: [ main ]
pull_request:
types:
- opened
- reopened
- synchronize
- ready_for_review
branches: [ main ]
jobs:
build:
name: "Build 🔨"
if: github.event.pull_request.draft == false
strategy:
matrix:
scheme:
- "Swiftfin"
- "Swiftfin tvOS"
runs-on: macos-12
steps:
- name: Checkout
uses: actions/checkout@v1
- name: Install SwiftGen
run: brew install swiftgen
- name: Cache Carthage
uses: actions/cache@v3
id: carthage-cache
with:
path: Carthage
key: ${{ runner.os }}-carthage-${{ hashFiles('**/Cartfile.resolved') }}
restore-keys: ${{ runner.os }}-carthage-
- name: Update Carthage
run: carthage update --use-xcframeworks --cache-builds
- name: Cache Swift packages
uses: actions/cache@v3
with:
path: PackageCache
key: ${{ runner.os }}-${{ matrix.scheme }}-spm-${{ hashFiles('**/Package.resolved') }}
restore-keys: ${{ runner.os }}-${{ matrix.scheme }}-spm-
- name: Build
uses: nick-fields/retry@v2
with:
max_attempts: 3
retry_on: error
timeout_minutes: 60
command: |
xcodebuild build -project "Swiftfin.xcodeproj" \
-scheme "${{ matrix.scheme }}" \
-clonedSourcePackagesDirPath PackageCache \
CODE_SIGN_IDENTITY="" CODE_SIGNING_REQUIRED=NO CODE_SIGNING_ALLOWED=NO