new: refactor testflight
This commit is contained in:
75
.github/workflows/build.yml
vendored
75
.github/workflows/build.yml
vendored
@@ -106,24 +106,6 @@ jobs:
|
||||
|
||||
|
||||
|
||||
|
||||
# - name: Download Provisioning Profile
|
||||
# if: ${{ inputs.upload-artifact && startsWith(matrix.os,'macos') }}
|
||||
# uses: Apple-Actions/download-provisioning-profiles@v1
|
||||
# with:
|
||||
# bundle-id: app.hiddify.com
|
||||
# issuer-id: ${{ secrets.APPSTORE_ISSUER_ID }}
|
||||
# api-key-id: ${{ secrets.APPSTORE_API_KEY_ID }}
|
||||
# api-private-key: ${{ secrets.APPSTORE_API_PRIVATE_KEY }}
|
||||
# - name: Download Provisioning Profile SingBoxPacketTunnel
|
||||
# if: ${{ inputs.upload-artifact && startsWith(matrix.os,'macos') }}
|
||||
# uses: Apple-Actions/download-provisioning-profiles@v1
|
||||
# with:
|
||||
# bundle-id: app.hiddify.com.SingBoxPacketTunnel
|
||||
# issuer-id: ${{ secrets.APPSTORE_ISSUER_ID }}
|
||||
# api-key-id: ${{ secrets.APPSTORE_API_KEY_ID }}
|
||||
# api-private-key: ${{ secrets.APPSTORE_API_PRIVATE_KEY }}
|
||||
|
||||
|
||||
- name: Setup Flutter
|
||||
uses: subosito/flutter-action@v2.12.0 #issue with 2.13
|
||||
@@ -272,20 +254,11 @@ jobs:
|
||||
|
||||
- name: Upload Artifact
|
||||
if: env.UPLOAD_ARTIFACT == 'true'
|
||||
uses: actions/upload-artifact@v3
|
||||
uses: actions/upload-artifact@v4
|
||||
with:
|
||||
name: artifact
|
||||
name: ${{matrix.platform}}
|
||||
path: ./out
|
||||
retention-days: 2
|
||||
- name: 'Upload app to TestFlight'
|
||||
if: ${{ inputs.upload-artifact && matrix.platform == 'ios' && inputs.tag-name != 'draft' }}
|
||||
uses: apple-actions/upload-testflight-build@v1
|
||||
continue-on-error: true
|
||||
with:
|
||||
app-path: 'out/Hiddify-iOS.ipa'
|
||||
issuer-id: ${{ secrets.APPSTORE_ISSUER_ID }}
|
||||
api-key-id: ${{ secrets.APPSTORE_API_KEY_ID }}
|
||||
api-private-key: ${{ secrets.APPSTORE_API_PRIVATE_KEY }}
|
||||
retention-days: 1
|
||||
|
||||
- name: Clean up keychain and provisioning profile
|
||||
if: ${{ always() && startsWith(matrix.os,'macos')}}
|
||||
@@ -305,10 +278,12 @@ jobs:
|
||||
# this fetches all history so that we can read each commit
|
||||
fetch-depth: 0
|
||||
- name: Download Artifact
|
||||
uses: actions/download-artifact@v3
|
||||
uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: artifact
|
||||
merge-multiple: true
|
||||
pattern: "*"
|
||||
path: ./out/
|
||||
|
||||
|
||||
- name: Display Files Structure
|
||||
run: ls -R
|
||||
@@ -349,9 +324,11 @@ jobs:
|
||||
- name: checkout
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- uses: actions/download-artifact@v3
|
||||
- name: Download Artifact
|
||||
uses: actions/download-artifact@v4
|
||||
with:
|
||||
name: artifact
|
||||
merge-multiple: true
|
||||
pattern: "*"
|
||||
path: ./out/
|
||||
|
||||
- name: Display Files Structure
|
||||
@@ -389,3 +366,33 @@ jobs:
|
||||
track: 'beta'
|
||||
|
||||
|
||||
upload-to-testflight:
|
||||
# if: ${{ inputs.upload-artifact && inputs.tag-name != 'draft' }}
|
||||
if: ${{ inputs.upload-artifact }}
|
||||
runs-on: macOS-latest
|
||||
timeout-minutes: 30
|
||||
steps:
|
||||
- name: Download Artifact
|
||||
uses: actions/download-artifact@v4
|
||||
with:
|
||||
merge-multiple: true
|
||||
pattern: "*ios*"
|
||||
path: ./out/
|
||||
|
||||
- uses: Apple-Actions/import-codesign-certs@v2
|
||||
with:
|
||||
p12-file-base64: ${{ secrets.APPLE_UPLOAD_CERTIFICATE_P12 }}
|
||||
p12-password: ${{ secrets.APPLE_CERTIFICATE_P12_PASSWORD }}
|
||||
|
||||
- uses: Apple-Actions/download-provisioning-profiles@v1
|
||||
with:
|
||||
bundle-id: app.hiddify.com
|
||||
issuer-id: ${{ secrets.APPSTORE_ISSUER_ID }}
|
||||
api-key-id: ${{ secrets.APPSTORE_KEY_ID }}
|
||||
api-private-key: ${{ secrets.APPSTORE_PRIVATE_KEY }}
|
||||
- uses: Apple-Actions/upload-testflight-build@v1
|
||||
with:
|
||||
app-path: 'out/Hiddify-iOS.ipa'
|
||||
issuer-id: ${{ secrets.APPSTORE_ISSUER_ID }}
|
||||
api-key-id: ${{ secrets.APPSTORE_API_KEY_ID }}
|
||||
api-private-key: ${{ secrets.APPSTORE_API_PRIVATE_KEY }}
|
||||
|
||||
Reference in New Issue
Block a user