-
Notifications
You must be signed in to change notification settings - Fork 35
64 lines (53 loc) · 2.13 KB
/
build-archive.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
name: Xcode - Build Archive
on:
push:
tags:
- 'v2.*.*'
env:
MARKETING_VERSION: 0.0.0
PATCH_VERSION: 0
jobs:
build:
name: Build sideloading package for TrollStore
runs-on: macos-13
steps:
- name: Setup Xcode version
uses: maxim-lobanov/setup-xcode@v1
with:
xcode-version: 15.1
- name: Checkout
uses: actions/checkout@v3
- name: Update version strings
run: |
export PATCH_VERSION=$(echo "${GITHUB_REF#refs/tags/v}" | cut -d. -f3)
echo "PATCH_VERSION=${PATCH_VERSION}" >> $GITHUB_ENV
echo "MARKETING_VERSION=${GITHUB_REF#refs/tags/v}" >> $GITHUB_ENV
xcrun agvtool new-version -all "${PATCH_VERSION}"
xcrun agvtool new-marketing-version "${GITHUB_REF#refs/tags/v}"
- name: Build helper
run: |
xcodebuild clean build archive -scheme ReveilHelper -project Reveil.xcodeproj -archivePath ReveilHelper.xcarchive CODE_SIGNING_ALLOWED=NO SKIP_INSTALL=NO | xcpretty && exit ${PIPESTATUS[0]}
- name: Build
run: |
PATH=$PWD/ReveilHelper.xcarchive/Products/usr/local/bin:$PATH xcodebuild clean build archive -scheme Reveil -project Reveil.xcodeproj -sdk iphoneos -destination 'generic/platform=iOS' -archivePath Reveil CODE_SIGNING_ALLOWED=NO | xcpretty && exit ${PIPESTATUS[0]}
- name: Package for sideloading
run: |
cd Reveil.xcarchive/Products/Applications
codesign --remove-signature Reveil.app
cd -
cd Reveil.xcarchive/Products
mv Applications Payload
zip -qr Reveil_${{ env.MARKETING_VERSION }}.tipa Payload
cd -
mv Reveil.xcarchive/Products/Reveil_${{ env.MARKETING_VERSION }}.tipa .
- name: Upload artifact
uses: actions/upload-artifact@v3
with:
name: Reveil_${{ env.MARKETING_VERSION }}
path: Reveil.xcarchive
- name: Upload release
uses: softprops/action-gh-release@v1
with:
token: ${{ secrets.RELEASE_GITHUB_TOKEN }}
body_path: CHANGELOG.md
files: Reveil_${{ env.MARKETING_VERSION }}.tipa