-
Notifications
You must be signed in to change notification settings - Fork 115
74 lines (64 loc) · 2.19 KB
/
ios.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
63
64
65
66
67
68
69
70
71
72
73
74
name: iOS Builds
on:
pull_request:
types: [opened, reopened, synchronize]
workflow_dispatch:
inputs:
use_expanded_matrix:
description: 'Use an expanded matrix?'
default: '0'
required: true
env:
GITHUB_TOKEN: ${{ github.token }}
concurrency:
group: ${{ github.workflow }}-${{ github.event_name }}-${{ github.head_ref || github.ref }}
cancel-in-progress: true
jobs:
prepare_matrix:
runs-on: ubuntu-20.04
outputs:
matrix_xcode_version: ${{ steps.export-result.outputs.matrix_xcode_version }}
steps:
- uses: actions/checkout@v3
with:
submodules: false
- name: Use expanded matrix
if: github.event.inputs.use_expanded_matrix == '1'
run: |
echo "EXPANDED_MATRIX_PARAM=-e=1" >> $GITHUB_ENV
- id: export-result
run: |
echo "matrix_xcode_version=$( python scripts/gha/print_matrix_configuration.py -w ios -k xcode_version ${EXPANDED_MATRIX_PARAM} )" >> $GITHUB_OUTPUT
build:
name: ios-${{ matrix.os }}-${{ matrix.xcode_version }}
runs-on: ${{ matrix.os }}
needs: prepare_matrix
strategy:
fail-fast: false
matrix:
os: [ 'macos-13' ]
xcode_version: ${{ fromJson(needs.prepare_matrix.outputs.matrix_xcode_version) }}
steps:
- name: Store git credentials for all git commands
# Forces all git commands to use authenticated https, to prevent throttling.
shell: bash
run: |
git config --global credential.helper 'store --file /tmp/git-credentials'
echo 'https://${{ github.token }}@github.com' > /tmp/git-credentials
- name: setup Xcode version (macos)
if: runner.os == 'macOS'
run: sudo xcode-select -s /Applications/Xcode_${{ matrix.xcode_version }}.app/Contents/Developer
- uses: actions/checkout@v3
with:
submodules: true
- name: Setup python
uses: actions/setup-python@v4
with:
python-version: 3.8
architecture: "x64"
- name: Install prerequisites
run: |
build_scripts/ios/install_prereqs.sh
- name: Build SDK
run: |
build_scripts/ios/build.sh -b ios_build -s .