Skip to content

Commit 371a022

Browse files
committed
ci: Build iOS app with fastlane
Adds all the signing keys and other credentials required for a successful production build. Additionally, opens the door to deploying via CI.
1 parent 9a27316 commit 371a022

File tree

2 files changed

+34
-2
lines changed

2 files changed

+34
-2
lines changed

.github/workflows/ios.yml

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
name: "iOS"
2+
3+
on:
4+
push:
5+
branches: ["master", "ci"]
6+
7+
jobs:
8+
build:
9+
timeout-minutes: 20
10+
runs-on: macos-latest
11+
steps:
12+
- uses: actions/checkout@v4
13+
- name: Setup Java
14+
uses: actions/setup-java@v4
15+
with:
16+
distribution: temurin
17+
java-version: 17
18+
- name: Setup Ruby
19+
uses: ruby/setup-ruby@v1
20+
with:
21+
bundler-cache: true
22+
- name: Install dependencies
23+
run: |
24+
yarn install
25+
yarn pods
26+
- name: Build Application
27+
run: |
28+
echo $SECRETS_TAR_GZ_B64 | base64 -d | tar -xz -C fastlane
29+
bundle exec fastlane ios build
30+
env:
31+
SECRETS_TAR_GZ_B64: ${{ secrets.SECRETS_TAR_GZ_B64 }}
32+
MATCH_GIT_BASIC_AUTHORIZATION: ${{ secrets.MATCH_GIT_BASIC_AUTHORIZATION }}

fastlane/Fastfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,14 +21,14 @@ platform :ios do
2121

2222
desc 'Fetch certificates and provisioning profiles'
2323
lane :certificates do
24+
setup_ci if ENV['CI']
2425
match(type: 'development', keychain_password: ENV['MATCH_PASSWORD'])
2526
match(type: 'appstore', keychain_password: ENV['MATCH_PASSWORD'])
2627
end
2728

2829
desc 'Build the iOS application.'
2930
lane :build do
30-
# certificates
31-
31+
certificates if ENV['CI']
3232
require "json"
3333
package_json = JSON.parse(File.read("../package.json"))
3434
increment_version_number_in_xcodeproj(

0 commit comments

Comments
 (0)