-
Notifications
You must be signed in to change notification settings - Fork 199
57 lines (47 loc) · 1.57 KB
/
build-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
name: Build iOS
on:
push:
branches:
- main
paths:
- '.github/workflows/build-ios.yml'
- 'ios/**'
- 'lib/**'
- 'pubspec.yaml'
jobs:
build:
runs-on: macos-14
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Setup Flutter
uses: subosito/flutter-action@v2
with:
flutter-version: '3.27.3'
- name: Install Apple Certificate
uses: apple-actions/import-codesign-certs@v1
with:
p12-file-base64: ${{ secrets.APPLE_CERTIFICATE_P12 }}
p12-password: ${{ secrets.APPLE_PASSWORD }}
- name: Install the provisioning profile
run: |
mkdir -p ~/Library/MobileDevice/Provisioning\ Profiles
echo "${{ secrets.APPLE_IOS_PROVISION_PROFILE }}" | base64 --decode > ~/Library/MobileDevice/Provisioning\ Profiles/Github_Actions.mobileprovision
- name: Set up keychain for signing
run: |
security create-keychain -p "" build.keychain
security default-keychain -s build.keychain
security unlock-keychain -p "" build.keychain
security set-keychain-settings -lut 3600 build.keychain
- name: Verify Certificate Installation
run: |
security find-identity -v -p codesigning
- name: Build iOS App
run: |
flutter pub get
flutter build ipa -v --export-options-plist="ios/ExportOptions.plist"
- name: Upload iOS Build
uses: actions/upload-artifact@v4
with:
name: maid-ios
path: build/ios/ipa