Skip to content

Commit 808b6b8

Browse files
committed
Add the ability to skip distributing builds
1 parent 900a769 commit 808b6b8

File tree

2 files changed

+15
-2
lines changed

2 files changed

+15
-2
lines changed

.github/workflows/CI-main.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,13 @@ on:
1515
patch_version:
1616
description: "Patch Version Override - e.g. '999'"
1717
type: string
18-
18+
ditribute:
19+
description: "Distribute to TestFlight"
20+
type: boolean
21+
default: false
1922
env:
2023
XCODE_VERSION: '15.4'
21-
24+
DISTRIBUTE_TO_TESTFLIGHT: ${{ github.event_name == 'push' || inputs.distribute }}
2225
jobs:
2326
resolve-values:
2427
name: "Resolve values"
@@ -86,4 +89,5 @@ jobs:
8689
build-version: ${{ needs.resolve-values.outputs.version_name }}
8790
build-number: ${{ needs.resolve-values.outputs.version_number }}
8891
xcode-version: $XCODE_VERSION
92+
distribute: $DISTRIBUTE_TO_TESTFLIGHT
8993
secrets: inherit

.github/workflows/build.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,10 @@ on:
3131
patch_version:
3232
description: "Patch Version Override - e.g. '999'"
3333
type: string
34+
ditribute:
35+
description: "Distribute to TestFlight"
36+
type: boolean
37+
default: false
3438
workflow_call:
3539
inputs:
3640
build-variant:
@@ -55,6 +59,10 @@ on:
5559
patch_version:
5660
description: "Patch Version Override - e.g. '999'"
5761
type: string
62+
ditribute:
63+
description: "Distribute to TestFlight"
64+
type: boolean
65+
default: false
5866
env:
5967
BUILD_VARIANT: ${{ inputs.build-variant || 'Beta' }}
6068
XCODE_VERSION: ${{ inputs.xcode-version || '15.4' }}
@@ -350,6 +358,7 @@ jobs:
350358
--apiIssuer "${{ secrets.APP_STORE_CONNECT_TEAM_ISSUER }}"
351359
352360
- name: Upload app to TestFlight with Fastlane
361+
if: ${{ inputs.ditribute }}
353362
run: |
354363
CHANGELOG="$(git show -s --format=%s)
355364
$GITHUB_REPOSITORY/$GITHUB_REF_NAME @ $GITHUB_SHA

0 commit comments

Comments
 (0)