Skip to content

Commit c268b9c

Browse files
committed
ci: Do not distrubute production build to public
1 parent 09a7b58 commit c268b9c

File tree

4 files changed

+10
-6
lines changed

4 files changed

+10
-6
lines changed

.github/workflows/build.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ jobs:
1919
fetch-depth: 0
2020

2121
- name: Deploy iOS Beta to TestFlight via Fastlane
22-
run: fastlane open_beta
22+
run: fastlane beta
2323
env:
2424
APP_STORE_CONNECT_TEAM_ID: "${{ secrets.APP_STORE_CONNECT_TEAM_ID }}"
2525
DEVELOPER_APP_ID: "${{ secrets.DEVELOPER_APP_ID }}"
@@ -38,6 +38,7 @@ jobs:
3838
APPLE_KEY_CONTENT: "${{ secrets.APPLE_KEY_CONTENT }}"
3939
JUDGE0_KEY: ""
4040
JUDGE0_ENDPOINT: ""
41+
DISTRIBUTE_EXTERNAL: "true"
4142

4243
- name: Upload Artifact
4344
uses: actions/upload-artifact@v3

.github/workflows/production.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ jobs:
1717
fetch-depth: 0
1818

1919
- name: Deploy production build to App Store via Fastlane
20-
run: fastlane open_beta
20+
run: fastlane beta
2121
env:
2222
APP_STORE_CONNECT_TEAM_ID: "${{ secrets.APP_STORE_CONNECT_TEAM_ID }}"
2323
DEVELOPER_APP_ID: "${{ secrets.DEVELOPER_APP_ID }}"
@@ -36,3 +36,4 @@ jobs:
3636
APPLE_KEY_CONTENT: "${{ secrets.APPLE_KEY_CONTENT }}"
3737
JUDGE0_KEY: "${{ secrets.JUDGE0_KEY }}"
3838
JUDGE0_ENDPOINT: "${{ secrets.JUDGE0_ENDPOINT }}"
39+
DISTRIBUTE_EXTERNAL: "false"

fastlane/Fastfile

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ GIT_AUTHORIZATION = ENV["GIT_AUTHORIZATION"]
1212

1313
JUDGE0_KEY = ENV["JUDGE0_KEY"]
1414
JUDGE0_ENDPOINT = ENV["JUDGE0_ENDPOINT"]
15+
DISTRIBUTE_EXTERNAL = ENV["DISTRIBUTE_EXTERNAL"] == "true"
1516

1617
def delete_temp_keychain(name)
1718
delete_keychain(
@@ -34,7 +35,7 @@ def ensure_temp_keychain(name, password)
3435
end
3536

3637
platform :ios do
37-
lane :open_beta do
38+
lane :beta do
3839
keychain_name = TEMP_KEYCHAIN_USER
3940
keychain_password = TEMP_KEYCHAIN_PASSWORD
4041
ensure_temp_keychain(keychain_name, keychain_password)
@@ -82,7 +83,7 @@ platform :ios do
8283
pilot(
8384
apple_id: "#{DEVELOPER_APP_ID}",
8485
app_identifier: "#{DEVELOPER_APP_IDENTIFIER}",
85-
distribute_external: true,
86+
distribute_external: DISTRIBUTE_EXTERNAL,
8687
notify_external_testers: true,
8788
ipa: "./Code.ipa",
8889
changelog: "GitHub Action automatic build. For detailed changes, " +
@@ -91,6 +92,7 @@ platform :ios do
9192
groups: ["Public"],
9293
wait_processing_interval: 300
9394
)
95+
9496

9597
delete_temp_keychain(keychain_name)
9698
end

fastlane/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,10 @@ For _fastlane_ installation instructions, see [Installing _fastlane_](https://do
1515

1616
## iOS
1717

18-
### ios open_beta
18+
### ios beta
1919

2020
```sh
21-
[bundle exec] fastlane ios open_beta
21+
[bundle exec] fastlane ios beta
2222
```
2323

2424

0 commit comments

Comments
 (0)