build: 55712324-398e-4334-a254-fc30c84b2e47
This commit is contained in:
+231
@@ -0,0 +1,231 @@
|
||||
workflows:
|
||||
android-debug:
|
||||
name: Android – Debug APK
|
||||
max_build_duration: 45
|
||||
instance_type: mac_mini_m2
|
||||
environment:
|
||||
node: 22
|
||||
java: 21
|
||||
cache:
|
||||
cache_paths:
|
||||
- $HOME/.gradle/caches
|
||||
- $HOME/.gradle/wrapper
|
||||
scripts:
|
||||
- name: Install dependencies
|
||||
script: npm install
|
||||
- name: Build web assets
|
||||
script: npm run build
|
||||
- name: Capacitor sync
|
||||
script: npx cap sync android
|
||||
- name: Build debug APK
|
||||
script: |
|
||||
cd android
|
||||
./gradlew assembleDebug --no-daemon
|
||||
artifacts:
|
||||
- android/app/build/outputs/apk/debug/app-debug.apk
|
||||
|
||||
android-release-apk:
|
||||
name: Android – Release APK
|
||||
max_build_duration: 45
|
||||
instance_type: mac_mini_m2
|
||||
environment:
|
||||
node: 22
|
||||
java: 21
|
||||
cache:
|
||||
cache_paths:
|
||||
- $HOME/.gradle/caches
|
||||
- $HOME/.gradle/wrapper
|
||||
scripts:
|
||||
- name: Install dependencies
|
||||
script: npm install
|
||||
- name: Build web assets
|
||||
script: npm run build
|
||||
- name: Write Firebase config
|
||||
script: |
|
||||
if [ -n "$GOOGLE_SERVICES_JSON" ]; then
|
||||
echo "$GOOGLE_SERVICES_JSON" | base64 --decode > android/app/google-services.json
|
||||
fi
|
||||
- name: Capacitor sync
|
||||
script: npx cap sync android
|
||||
- name: Set up keystore
|
||||
script: echo "$CM_KEYSTORE" | base64 --decode > /tmp/keystore.jks
|
||||
- name: Build Release APK
|
||||
script: |
|
||||
cd android
|
||||
./gradlew assembleRelease \
|
||||
-Pandroid.injected.signing.store.file=/tmp/keystore.jks \
|
||||
-Pandroid.injected.signing.store.password=$CM_KEYSTORE_PASSWORD \
|
||||
-Pandroid.injected.signing.key.alias=$CM_KEY_ALIAS \
|
||||
-Pandroid.injected.signing.key.password=$CM_KEY_PASSWORD \
|
||||
--no-daemon
|
||||
artifacts:
|
||||
- android/app/build/outputs/apk/release/app-release.apk
|
||||
|
||||
android-release-aab:
|
||||
name: Android – Release AAB
|
||||
max_build_duration: 45
|
||||
instance_type: mac_mini_m2
|
||||
environment:
|
||||
node: 22
|
||||
java: 21
|
||||
cache:
|
||||
cache_paths:
|
||||
- $HOME/.gradle/caches
|
||||
- $HOME/.gradle/wrapper
|
||||
scripts:
|
||||
- name: Install dependencies
|
||||
script: npm install
|
||||
- name: Build web assets
|
||||
script: npm run build
|
||||
- name: Write Firebase config
|
||||
script: |
|
||||
if [ -n "$GOOGLE_SERVICES_JSON" ]; then
|
||||
echo "$GOOGLE_SERVICES_JSON" | base64 --decode > android/app/google-services.json
|
||||
fi
|
||||
- name: Capacitor sync
|
||||
script: npx cap sync android
|
||||
- name: Set up keystore
|
||||
script: echo "$CM_KEYSTORE" | base64 --decode > /tmp/keystore.jks
|
||||
- name: Build Release AAB
|
||||
script: |
|
||||
cd android
|
||||
./gradlew bundleRelease \
|
||||
-Pandroid.injected.signing.store.file=/tmp/keystore.jks \
|
||||
-Pandroid.injected.signing.store.password=$CM_KEYSTORE_PASSWORD \
|
||||
-Pandroid.injected.signing.key.alias=$CM_KEY_ALIAS \
|
||||
-Pandroid.injected.signing.key.password=$CM_KEY_PASSWORD \
|
||||
--no-daemon
|
||||
artifacts:
|
||||
- android/app/build/outputs/bundle/release/app-release.aab
|
||||
|
||||
android-release:
|
||||
name: Android – Publish to Google Play
|
||||
max_build_duration: 60
|
||||
instance_type: mac_mini_m2
|
||||
environment:
|
||||
node: 22
|
||||
java: 21
|
||||
cache:
|
||||
cache_paths:
|
||||
- $HOME/.gradle/caches
|
||||
- $HOME/.gradle/wrapper
|
||||
scripts:
|
||||
- name: Install dependencies
|
||||
script: npm install
|
||||
- name: Build web assets
|
||||
script: npm run build
|
||||
- name: Write Firebase config
|
||||
script: |
|
||||
if [ -n "$GOOGLE_SERVICES_JSON" ]; then
|
||||
echo "$GOOGLE_SERVICES_JSON" | base64 --decode > android/app/google-services.json
|
||||
fi
|
||||
- name: Capacitor sync
|
||||
script: npx cap sync android
|
||||
- name: Set up keystore
|
||||
script: echo "$CM_KEYSTORE" | base64 --decode > /tmp/keystore.jks
|
||||
- name: Build Release AAB
|
||||
script: |
|
||||
cd android
|
||||
./gradlew bundleRelease \
|
||||
-Pandroid.injected.signing.store.file=/tmp/keystore.jks \
|
||||
-Pandroid.injected.signing.store.password=$CM_KEYSTORE_PASSWORD \
|
||||
-Pandroid.injected.signing.key.alias=$CM_KEY_ALIAS \
|
||||
-Pandroid.injected.signing.key.password=$CM_KEY_PASSWORD \
|
||||
--no-daemon
|
||||
publishing:
|
||||
google_play:
|
||||
credentials: $GOOGLE_PLAY_SERVICE_ACCOUNT_CREDENTIALS
|
||||
track: $GOOGLE_PLAY_TRACK
|
||||
submit_as_draft: false
|
||||
artifacts:
|
||||
- android/app/build/outputs/bundle/release/app-release.aab
|
||||
|
||||
ios-debug:
|
||||
name: iOS – Debug IPA
|
||||
max_build_duration: 60
|
||||
instance_type: mac_mini_m2
|
||||
environment:
|
||||
node: 22
|
||||
xcode: latest
|
||||
cache:
|
||||
cache_paths:
|
||||
- $HOME/Library/Caches/CocoaPods
|
||||
scripts:
|
||||
- name: Install dependencies
|
||||
script: npm install
|
||||
- name: Build web assets
|
||||
script: npm run build
|
||||
- name: Capacitor sync
|
||||
script: npx cap sync ios
|
||||
- name: Install CocoaPods
|
||||
script: cd ios/App && pod install
|
||||
- name: Build IPA
|
||||
script: |
|
||||
xcode-project build-ipa \
|
||||
--workspace ios/App/App.xcworkspace \
|
||||
--scheme App
|
||||
artifacts:
|
||||
- build/ios/ipa/*.ipa
|
||||
|
||||
ios-release:
|
||||
name: iOS – Release IPA
|
||||
max_build_duration: 90
|
||||
instance_type: mac_mini_m2
|
||||
environment:
|
||||
node: 22
|
||||
xcode: latest
|
||||
cache:
|
||||
cache_paths:
|
||||
- $HOME/Library/Caches/CocoaPods
|
||||
scripts:
|
||||
- name: Install dependencies
|
||||
script: npm install
|
||||
- name: Build web assets
|
||||
script: npm run build
|
||||
- name: Write Firebase config
|
||||
script: |
|
||||
if [ -n "$GOOGLE_SERVICE_INFO_PLIST" ]; then
|
||||
echo "$GOOGLE_SERVICE_INFO_PLIST" | base64 --decode > ios/App/App/GoogleService-Info.plist
|
||||
fi
|
||||
- name: Capacitor sync
|
||||
script: npx cap sync ios
|
||||
- name: Install CocoaPods
|
||||
script: cd ios/App && pod install
|
||||
- name: Set up signing
|
||||
script: |
|
||||
keychain initialize
|
||||
if [ -n "$APP_STORE_CONNECT_PRIVATE_KEY" ]; then
|
||||
app-store-connect fetch-signing-files \
|
||||
$(xcode-project detect-bundle-id) \
|
||||
--type IOS_APP_STORE \
|
||||
--certificate-key=@env:APP_STORE_CONNECT_PRIVATE_KEY \
|
||||
--issuer-id=$APP_STORE_CONNECT_ISSUER_ID \
|
||||
--key-id=$APP_STORE_CONNECT_KEY_IDENTIFIER \
|
||||
--create
|
||||
xcode-project use-profiles
|
||||
else
|
||||
echo "$CM_CERTIFICATE" | base64 --decode > /tmp/cert.p12
|
||||
keychain add-certificates \
|
||||
--certificate /tmp/cert.p12 \
|
||||
--certificate-password "$CM_CERTIFICATE_PASSWORD"
|
||||
echo "$CM_PROVISIONING_PROFILE" | base64 --decode > /tmp/profile.mobileprovision
|
||||
xcode-project use-profiles --provisioning-profile-path /tmp/profile.mobileprovision
|
||||
fi
|
||||
- name: Build IPA
|
||||
script: |
|
||||
xcode-project build-ipa \
|
||||
--workspace ios/App/App.xcworkspace \
|
||||
--scheme App \
|
||||
--config Release
|
||||
- name: Publish
|
||||
script: |
|
||||
if [ "$SUBMIT_TO_TESTFLIGHT" = "true" ] || [ "$SUBMIT_TO_APP_STORE" = "true" ]; then
|
||||
app-store-connect publish \
|
||||
--certificate-key=@env:APP_STORE_CONNECT_PRIVATE_KEY \
|
||||
--issuer-id=$APP_STORE_CONNECT_ISSUER_ID \
|
||||
--key-id=$APP_STORE_CONNECT_KEY_IDENTIFIER \
|
||||
--submit-to-testflight=$SUBMIT_TO_TESTFLIGHT \
|
||||
--submit-to-app-store=$SUBMIT_TO_APP_STORE
|
||||
fi
|
||||
artifacts:
|
||||
- build/ios/ipa/*.ipa
|
||||
Reference in New Issue
Block a user