-
Notifications
You must be signed in to change notification settings - Fork 0
126 lines (109 loc) · 3.35 KB
/
ci-pipeline.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
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
name: CI Pipeline
on:
pull_request:
branches:
- master
jobs:
tsc:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: '22'
- name: Cache Node.js modules
uses: actions/cache@v3
with:
path: |
~/.yarn
~/.cache
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-
- name: Install dependencies
run: yarn install --frozen-lockfile
- name: Run TypeScript compiler
run: yarn run tsc
lint:
runs-on: ubuntu-latest
needs: tsc
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Cache Node.js modules
uses: actions/cache@v4
with:
path: |
~/.yarn
~/.cache
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
restore-keys: |
${{ runner.os }}-node-
- name: Install dependencies
run: yarn install --frozen-lockfile
- name: Run Linting
run: yarn run lint
# We will add this later with e2e tests and when I will setup jest environments :)
# test:
# runs-on: ubuntu-latest
# needs: lint # This job depends on lint
# steps:
# - name: Checkout code
# uses: actions/checkout@v3
#
# - name: Install dependencies
# run: npm install
#
# - name: Run Tests
# run: npm test
# Fourth job: Build iOS
build-ios:
runs-on: macos-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: '3.3.0'
- name: Install Fastlane
run: |
cd ios
rm -rf Gemfile.lock
gem install bundler -v 2.4.22
bundle install
- name: Set up Fastlane API Key
run: |
echo "${{ secrets.APP_STORE_CONNECT_PRIVATE_KEY }}" > ios/fastlane/AuthKey.p8
env:
APP_STORE_CONNECT_PRIVATE_KEY: ${{ secrets.APP_STORE_CONNECT_PRIVATE_KEY }}
- name: Run Fastlane Lane
run: |
cd ios
bundle exec fastlane beta
env:
APP_STORE_CONNECT_KEY_IDENTIFIER: ${{ secrets.APP_STORE_CONNECT_KEY_IDENTIFIER }}
APP_STORE_CONNECT_ISSUER_ID: ${{ secrets.APP_STORE_CONNECT_ISSUER_ID }}
DEVELOPER_APP_ID: ${{ secrets.DEVELOPER_APP_ID }}
DEVELOPER_APP_IDENTIFIER: ${{ secrets.DEVELOPER_APP_IDENTIFIER }}
MATCH_PASSWORD: ${{ secrets.MATCH_PASSWORD }}
PROVISIONING_PROFILE_SPECIFIER: ${{ secrets.PROVISIONING_PROFILE_SPECIFIER }}
TEMP_KEYCHAIN_USER: ${{ secrets.TEMP_KEYCHAIN_USER }}
TEMP_KEYCHAIN_PASSWORD: ${{ secrets.TEMP_KEYCHAIN_PASSWORD }}
GIT_AUTHORIZATION: ${{ secrets.GIT_AUTHORIZATION }}
PROVISIONING_PROFILE_ID: ${{ secrets.PROVISIONING_PROFILE_ID }}
# Fifth job: Build Android
# build_android:
# runs-on: ubuntu-latest
# needs: lint # This job depends on test
# steps:
# - name: Checkout code
# uses: actions/checkout@v4
#
# - name: Install dependencies
# run: npm install
#
# - name: Run Fastlane for Android
# run: fastlane android build