1- name : publish-beta
1+ name : Publish Android APK and TestFlight Betas
22on :
33 push :
44 branches :
55 - ' main'
66jobs :
7- publish-ios- beta :
8- runs-on : macos-latest
7+ publish-beta :
8+ runs-on : macos-15
99 steps :
1010 - name : 🛒 Checkout
1111 uses : actions/checkout@v4
@@ -16,40 +16,82 @@ jobs:
1616 uses : actions/setup-node@v4
1717 with :
1818 node-version : 20
19+
20+ - name : 🧵 Run yarn install
21+ run : yarn install
1922
20- - name : 💬 Echo package.json version to Github ENV
21- run : echo VERSION_NUMBER=$(npm version minor --tag-version-prefix="" --no-commit-hooks) >> $GITHUB_ENV
23+ - name : 🍫 Install CocoaPods
24+ run : yarn pod:install
25+
26+ - name : ➕ Version Up
27+ run : yarn react-native bump-version --type patch
2228
23- - name : 🟢 Run npm run init
24- run : npm run init:new-arch
29+
30+ - name : 💬 Echo package.json version to Github ENV
31+ run : echo VERSION_NUMBER=$(node -p -e "require('./package.json').version") >> $GITHUB_ENV
2532
2633 - name : 🤫 Output App Store Connect API Key JSON to Fastlane
2734 run : echo -e '${{ secrets.APPSTORE_CONNECT_API_KEY_JSON }}' > appstore_connect_api_key.json
2835 working-directory : ./ios/fastlane
2936
37+ - name : 🚀 Run Android fastlane build
38+ run : yarn fastlane:android:build
39+
3040 - name : 🚀 Run iOS fastlane build and publish to TestFlight
31- run : npm run fastlane:ios:beta
41+ run : yarn fastlane:ios:beta
3242 env :
3343 APPSTORE_CONNECT_API_KEY_JSON : ${{ secrets.APPSTORE_CONNECT_API_KEY_JSON }}
3444 FASTLANE_APPLE_APPLICATION_SPECIFIC_PASSWORD : ${{ secrets.FASTLANE_APPLE_APPLICATION_SPECIFIC_PASSWORD }}
3545 MATCH_PASSWORD : ${{ secrets.MATCH_PASSWORD }}
3646 MATCH_REPO_PAT : " anultravioletaurora:${{ secrets.SIGNING_REPO_PAT }}"
3747
38- - name : 🚀 Run Android fastlane build
39- run : npm run fastlane:android:build
40-
4148 # Commit Fastlane Xcode build number increment
42- - name : 🔢 Commit Xcode build number increment
43- uses : stefanzweifel/git-auto-commit-action@v5
44- with :
45- commit_message : " [skip actions]"
46- file_pattern : " ios/Jellify.xcodeproj/project.pbxproj"
47-
49+ - name : 🔢 Commit changes for version increment
50+ run : |
51+ git config --global user.email "jellify@cosmonautical.com"
52+ git config --global user.name "anultravioletaurora"
53+ git add package.json
54+ git add ios/Jellify.xcodeproj/project.pbxproj
55+ git add android/app/build.gradle
56+ git commit -m "[skip actions]"
57+ git push origin main
58+
59+ - name : 🔢 Set artifact version numbers
60+ run : |
61+ # Create artifacts folder for uploading to release
62+ mkdir artifacts
63+
64+ # Move the iOS IPA
65+ mv ./ios/Jellify.ipa ./artifacts/Jellify-${{ env.VERSION_NUMBER }}.ipa
66+
67+ # Move and rename all android release APKs
68+ for apk in ./android/app/build/outputs/apk/release/*.apk; do
69+ filename=$(basename "$apk")
70+ newname="Jellify-${{ env.VERSION_NUMBER }}-${filename}"
71+ cp "$apk" "./artifacts/$newname"
72+ done
73+
4874 - name : 🎉 Create Github release
4975 uses : ncipollo/release-action@v1
76+ id : githubRelease
5077 with :
51- artifacts : " ios/Jellify.ipa,android/app/build/outputs/apk/release/app-release.apk "
78+ artifacts : " ./artifacts/* "
5279 name : ${{ env.VERSION_NUMBER }}
80+ generateReleaseNotes : true
5381 prerelease : true
5482 tag : ${{ env.VERSION_NUMBER }}
5583 token : ${{ secrets.SIGNING_REPO_PAT }}
84+
85+
86+
87+
88+ - name : 🗣️ Notify on Discord
89+ run : |
90+ cd ios
91+ bundle exec fastlane notifyOnDiscord
92+ cd ..
93+
94+ env :
95+ DISCORD_WEBHOOK_URL : ${{ secrets.DISCORD_WEBHOOK_URL }}
96+ APP_VERSION : ${{ env.VERSION_NUMBER }}
97+ release_url : ${{ steps.githubRelease.outputs.html_url }}
0 commit comments