-
Notifications
You must be signed in to change notification settings - Fork 22
76 lines (67 loc) · 1.97 KB
/
Copy pathios.yml
File metadata and controls
76 lines (67 loc) · 1.97 KB
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
name: Build iOS
on:
push:
branches: ["main"]
pull_request:
branches: ["main"]
jobs:
changes:
runs-on: ubuntu-latest
permissions:
contents: read
outputs:
ios: ${{ steps.filter.outputs.ios }}
steps:
- uses: actions/checkout@v4
- uses: dorny/paths-filter@v3
id: filter
with:
filters: |
ios:
- 'ios/**'
- 'assets/**'
- 'lib/**'
- 'pubspec.yaml'
iOS:
needs: changes
if: ${{ needs.changes.outputs.ios == 'true' }}
runs-on: macos-latest
permissions:
contents: read
steps:
- uses: actions/checkout@v4
- name: Setup Flutter
uses: subosito/flutter-action@v2
with:
channel: "stable"
cache: true
# The iOS build uses Swift Package Manager, not CocoaPods (there is no
# Podfile). Cache SPM's clone/artifact store keyed on the resolved pins.
- name: Cache Swift Packages
uses: actions/cache@v4
with:
path: |
~/Library/Caches/org.swift.swiftpm
~/Library/Developer/Xcode/DerivedData/**/SourcePackages
key: ${{ runner.os }}-spm-${{ hashFiles('ios/Runner.xcworkspace/xcshareddata/swiftpm/Package.resolved') }}
restore-keys: |
${{ runner.os }}-spm-
- name: Install dependencies and run build_runner
run: |
flutter pub get
dart run build_runner build --delete-conflicting-outputs
- name: Build iOS App and create IPA
run: |
flutter build ios --debug --no-codesign
mkdir -p Payload
cp -R build/ios/iphoneos/Runner.app Payload/Runner.app
zip -qr DPIP.ipa Payload
- name: Upload Artifacts
uses: actions/upload-artifact@v4
with:
name: DPIP-iOS
path: |
build/ios/iphoneos/Runner.app
DPIP.ipa
retention-days: 7
compression-level: 6