Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Automate Testflight beta releases #238

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
34 changes: 34 additions & 0 deletions .github/workflows/testflight.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
name: Beta Release
on:
push:
tags:
- v*.*.*
jobs:
test:
name: TestFlight
runs-on: macOS-latest
steps:
- name: Checkout
uses: actions/checkout@master
- name: XCode Setup
uses: maxim-lobanov/setup-xcode@v1
with:
xcode-version: '12.2'
- uses: actions/cache@v2
with:
path: Carthage
key: ${{ runner.os }}-carthage-${{ hashFiles('**/Cartfile.resolved') }}
restore-keys: |
${{ runner.os }}-carthage-
- name: Carthage
run: |
./carthage.sh bootstrap --no-use-binaries --platform iOS --cache-builds
- name: Archive and upload to Testflight 🚀
run: |
bundle install && bundle exec fastlane beta
env:
CI: 1
MATCH_GIT_PRIVATE_KEY: ${{ secrets.MATCH_GIT_PRIVATE_KEY }}
MATCH_PASSWORD: ${{ secrets.MATCH_PASSWORD }}
FASTLANE_APPLE_APPLICATION_SPECIFIC_PASSWORD: ${{ secrets.FASTLANE_APPLE_APPLICATION_SPECIFIC_PASSWORD }}

8 changes: 4 additions & 4 deletions DEV-Simple.xcodeproj/project.pbxproj
100755 → 100644
Original file line number Diff line number Diff line change
Expand Up @@ -577,7 +577,7 @@
CODE_SIGN_ENTITLEMENTS = "DEV-Simple/DEV-Simple.entitlements";
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 1;
CURRENT_PROJECT_VERSION = 5;
DEVELOPMENT_TEAM = R9SWHSQNV8;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
Expand All @@ -589,7 +589,7 @@
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 1.5.0;
MARKETING_VERSION = 1.5.1;
PRODUCT_BUNDLE_IDENTIFIER = to.dev.ios;
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = "";
Expand All @@ -605,7 +605,7 @@
CODE_SIGN_ENTITLEMENTS = "DEV-Simple/DEV-Simple.entitlements";
CODE_SIGN_IDENTITY = "Apple Development";
CODE_SIGN_STYLE = Automatic;
CURRENT_PROJECT_VERSION = 1;
CURRENT_PROJECT_VERSION = 5;
DEVELOPMENT_TEAM = R9SWHSQNV8;
FRAMEWORK_SEARCH_PATHS = (
"$(inherited)",
Expand All @@ -617,7 +617,7 @@
"$(inherited)",
"@executable_path/Frameworks",
);
MARKETING_VERSION = 1.5.0;
MARKETING_VERSION = 1.5.1;
PRODUCT_BUNDLE_IDENTIFIER = to.dev.ios;
PRODUCT_NAME = "$(TARGET_NAME)";
PROVISIONING_PROFILE_SPECIFIER = "";
Expand Down
2 changes: 1 addition & 1 deletion DEV-Simple/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@
</dict>
</array>
<key>CFBundleVersion</key>
<string>$(CURRENT_PROJECT_VERSION)</string>
<string>5</string>
<key>LSRequiresIPhoneOS</key>
<true/>
<key>NSAppTransportSecurity</key>
Expand Down
2 changes: 1 addition & 1 deletion DEV-SimpleTests/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,6 @@
<key>CFBundleShortVersionString</key>
<string>1.0</string>
<key>CFBundleVersion</key>
<string>1</string>
<string>5</string>
</dict>
</plist>
2 changes: 1 addition & 1 deletion DEV-SimpleUITests/Info.plist
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,6 @@
<key>CFBundleShortVersionString</key>
<string>1.0</string>
<key>CFBundleVersion</key>
<string>1</string>
<string>5</string>
</dict>
</plist>
10 changes: 9 additions & 1 deletion fastlane/Fastfile
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,16 @@ platform :ios do
run_tests(
scheme: "DEV-Simple",
clean: true,
devices: ["iPhone 11 Pro Max"],
devices: ["iPhone 12 Pro Max"],
code_coverage: true
)
end

desc "TestFlight upload"
lane :beta do
increment_build_number
match(type: "appstore", readonly: true, app_identifier: "to.dev.ios")
gym(scheme: "DEV-Simple", configuration: "Release", clean: true)
upload_to_testflight(skip_waiting_for_build_processing: true)
end
end
5 changes: 5 additions & 0 deletions fastlane/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,11 @@ or alternatively using `brew install fastlane`
fastlane ios test
```
Runs all the tests
### ios beta
```
fastlane ios beta
```
TestFlight upload

----

Expand Down