Skip to content

Commit 308b102

Browse files
author
Lalit Sharma
committed
ci(mobile): upload Wear OS AAB to Play internal track
- switch Wear build from APK to AAB in EAS (`:wear:bundleRelease`, `wear-release.aab`) - update CI workflow to collect, validate, and upload the Wear AAB to `com.lallimaven.eclipsetimer.wear` - bump mobile version to 1.1.7 and add changelog entry
1 parent f7ac475 commit 308b102

4 files changed

Lines changed: 63 additions & 30 deletions

File tree

.github/workflows/eas-build.yml

Lines changed: 55 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ jobs:
114114
exit 1
115115
fi
116116
117-
- name: Build iOS and Android (AAB + APK + Wear APK)
117+
- name: Build iOS and Android (AAB + APK + Wear AAB)
118118
working-directory: apps/mobile
119119
env:
120120
EAS_LOCAL_BUILD_ARTIFACTS_DIR: ${{ github.workspace }}/artifacts/raw
@@ -166,7 +166,7 @@ jobs:
166166
ios_asset_name="${artifact_prefix}.ipa"
167167
android_aab_asset_name="${artifact_prefix}.aab"
168168
android_apk_asset_name="${artifact_prefix}.apk"
169-
wear_apk_asset_name="${artifact_prefix}-wear.apk"
169+
wear_aab_asset_name="${artifact_prefix}-wear.aab"
170170
171171
ios_artifact="$(find artifacts/raw -type f -name '*.ipa' | head -n 1 || true)"
172172
if [ -z "$ios_artifact" ]; then
@@ -175,12 +175,38 @@ jobs:
175175
fi
176176
cp "$ios_artifact" "artifacts/submission/$ios_asset_name"
177177
178-
android_artifact="$(find artifacts/raw -type f -name '*.aab' | head -n 1 || true)"
179-
if [ -z "$android_artifact" ]; then
178+
aab_artifacts=()
179+
while IFS= read -r artifact; do
180+
aab_artifacts+=("$artifact")
181+
done < <(find artifacts/raw -type f -name '*.aab' | sort)
182+
183+
if [ "${#aab_artifacts[@]}" -eq 0 ]; then
184+
echo "Missing Android artifacts (.aab) in artifacts/raw."
185+
exit 1
186+
fi
187+
188+
android_aab_artifact="$(printf '%s\n' "${aab_artifacts[@]}" | grep -iv 'wear' | head -n 1 || true)"
189+
if [ -z "$android_aab_artifact" ]; then
190+
android_aab_artifact="${aab_artifacts[0]}"
191+
fi
192+
if [ -z "$android_aab_artifact" ]; then
180193
echo "Missing Android artifact (.aab) in artifacts/raw."
181194
exit 1
182195
fi
183-
cp "$android_artifact" "artifacts/submission/$android_aab_asset_name"
196+
cp "$android_aab_artifact" "artifacts/submission/$android_aab_asset_name"
197+
198+
wear_aab_artifact="$(find artifacts/raw -type f -name 'wear-release.aab' | head -n 1 || true)"
199+
if [ -z "$wear_aab_artifact" ]; then
200+
wear_aab_artifact="$(printf '%s\n' "${aab_artifacts[@]}" | grep -i 'wear' | head -n 1 || true)"
201+
fi
202+
if [ -z "$wear_aab_artifact" ] && [ "${#aab_artifacts[@]}" -ge 2 ]; then
203+
wear_aab_artifact="${aab_artifacts[$((${#aab_artifacts[@]} - 1))]}"
204+
fi
205+
if [ -z "$wear_aab_artifact" ] || [ "$wear_aab_artifact" = "$android_aab_artifact" ]; then
206+
echo "Missing Wear OS artifact (.aab) in artifacts/raw."
207+
exit 1
208+
fi
209+
cp "$wear_aab_artifact" "artifacts/submission/$wear_aab_asset_name"
184210
185211
apk_artifacts=()
186212
while IFS= read -r artifact; do
@@ -202,19 +228,6 @@ jobs:
202228
fi
203229
cp "$android_apk_artifact" "artifacts/submission/$android_apk_asset_name"
204230
205-
wear_apk_artifact="$(find artifacts/raw -type f -name 'wear-release.apk' | head -n 1 || true)"
206-
if [ -z "$wear_apk_artifact" ]; then
207-
wear_apk_artifact="$(find artifacts/raw -type f -name '*wear*.apk' | head -n 1 || true)"
208-
fi
209-
if [ -z "$wear_apk_artifact" ] && [ "${#apk_artifacts[@]}" -ge 2 ]; then
210-
wear_apk_artifact="${apk_artifacts[$((${#apk_artifacts[@]} - 1))]}"
211-
fi
212-
if [ -z "$wear_apk_artifact" ] || [ "$wear_apk_artifact" = "$android_apk_artifact" ]; then
213-
echo "Missing Wear OS artifact (.apk) in artifacts/raw."
214-
exit 1
215-
fi
216-
cp "$wear_apk_artifact" "artifacts/submission/$wear_apk_asset_name"
217-
218231
ls -lah artifacts/submission
219232
220233
- name: Upload build artifacts
@@ -418,7 +431,7 @@ jobs:
418431
echo "ios=${artifact_prefix}.ipa"
419432
echo "android_aab=${artifact_prefix}.aab"
420433
echo "android_apk=${artifact_prefix}.apk"
421-
echo "wear_apk=${artifact_prefix}-wear.apk"
434+
echo "wear_aab=${artifact_prefix}-wear.aab"
422435
} >> "$GITHUB_OUTPUT"
423436
424437
- name: Validate submission artifacts
@@ -428,7 +441,7 @@ jobs:
428441
ios_asset="${{ steps.artifact_names.outputs.ios }}"
429442
android_aab_asset="${{ steps.artifact_names.outputs.android_aab }}"
430443
android_apk_asset="${{ steps.artifact_names.outputs.android_apk }}"
431-
wear_apk_asset="${{ steps.artifact_names.outputs.wear_apk }}"
444+
wear_aab_asset="${{ steps.artifact_names.outputs.wear_aab }}"
432445
433446
if [ ! -f "$artifact_root/$ios_asset" ]; then
434447
echo "Missing iOS artifact at $artifact_root/$ios_asset."
@@ -445,8 +458,8 @@ jobs:
445458
exit 1
446459
fi
447460
448-
if [ ! -f "$artifact_root/$wear_apk_asset" ]; then
449-
echo "Missing Wear OS artifact at $artifact_root/$wear_apk_asset."
461+
if [ ! -f "$artifact_root/$wear_aab_asset" ]; then
462+
echo "Missing Wear OS artifact at $artifact_root/$wear_aab_asset."
450463
exit 1
451464
fi
452465
@@ -461,7 +474,7 @@ jobs:
461474
echo "artifacts/submission/${{ steps.artifact_names.outputs.ios }}"
462475
echo "artifacts/submission/${{ steps.artifact_names.outputs.android_aab }}"
463476
echo "artifacts/submission/${{ steps.artifact_names.outputs.android_apk }}"
464-
echo "artifacts/submission/${{ steps.artifact_names.outputs.wear_apk }}"
477+
echo "artifacts/submission/${{ steps.artifact_names.outputs.wear_aab }}"
465478
echo "EOF"
466479
} >> "$GITHUB_OUTPUT"
467480
@@ -675,8 +688,6 @@ jobs:
675688
serviceAccountJsonPlainText: ${{ secrets.GOOGLE_PLAY_SERVICE_ACCOUNT_JSON }}
676689
packageName: com.lallimaven.eclipsetimer
677690
releaseFiles: artifacts/submission/${{ steps.artifact_names.outputs.android_aab }}
678-
# Wear APK upload is temporarily disabled because Google Play currently rejects APK uploads for this app.
679-
# releaseFiles: artifacts/submission/${{ steps.artifact_names.outputs.android_aab }},artifacts/submission/${{ steps.artifact_names.outputs.wear_apk }}
680691
track: internal
681692
whatsNewDirectory: ${{ steps.store_notes.outputs.play_whatsnew_dir }}
682693

@@ -687,8 +698,25 @@ jobs:
687698
serviceAccountJsonPlainText: ${{ secrets.GOOGLE_PLAY_SERVICE_ACCOUNT_JSON }}
688699
packageName: com.lallimaven.eclipsetimer
689700
releaseFiles: artifacts/submission/${{ steps.artifact_names.outputs.android_aab }}
690-
# Wear APK upload is temporarily disabled because Google Play currently rejects APK uploads for this app.
691-
# releaseFiles: artifacts/submission/${{ steps.artifact_names.outputs.android_aab }},artifacts/submission/${{ steps.artifact_names.outputs.wear_apk }}
701+
track: internal
702+
703+
- name: Upload Wear OS artifact to Google Play (with notes)
704+
if: ${{ steps.store_notes.outputs.has_store_notes == 'true' }}
705+
uses: r0adkll/upload-google-play@v1
706+
with:
707+
serviceAccountJsonPlainText: ${{ secrets.GOOGLE_PLAY_SERVICE_ACCOUNT_JSON }}
708+
packageName: com.lallimaven.eclipsetimer.wear
709+
releaseFiles: artifacts/submission/${{ steps.artifact_names.outputs.wear_aab }}
710+
track: internal
711+
whatsNewDirectory: ${{ steps.store_notes.outputs.play_whatsnew_dir }}
712+
713+
- name: Upload Wear OS artifact to Google Play
714+
if: ${{ steps.store_notes.outputs.has_store_notes != 'true' }}
715+
uses: r0adkll/upload-google-play@v1
716+
with:
717+
serviceAccountJsonPlainText: ${{ secrets.GOOGLE_PLAY_SERVICE_ACCOUNT_JSON }}
718+
packageName: com.lallimaven.eclipsetimer.wear
719+
releaseFiles: artifacts/submission/${{ steps.artifact_names.outputs.wear_aab }}
692720
track: internal
693721

694722
- name: Create GitHub release with mobile artifacts

CHANGELOG.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,11 @@ All notable changes to this project will be documented in this file.
55
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
66
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
77

8+
## [1.1.7] — 2026-02-21
9+
10+
### Changed
11+
- Updated `.github/workflows/eas-build.yml` to upload the Wear OS AAB (`com.lallimaven.eclipsetimer.wear`) to Google Play internal track in addition to the phone AAB, so releases for both packages are created directly from CI.
12+
813
## [1.1.6] — 2026-02-21
914

1015
### Fixed

apps/mobile/eas.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,8 @@
4848
"extends": "production",
4949
"autoIncrement": false,
5050
"android": {
51-
"gradleCommand": ":wear:assembleRelease",
52-
"applicationArchivePath": "android/wear/build/outputs/apk/release/wear-release.apk"
51+
"gradleCommand": ":wear:bundleRelease",
52+
"applicationArchivePath": "android/wear/build/outputs/bundle/release/wear-release.aab"
5353
}
5454
}
5555
},

apps/mobile/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@eclipse-timer/mobile",
3-
"version": "1.1.6",
3+
"version": "1.1.7",
44
"private": true,
55
"main": "index.js",
66
"scripts": {

0 commit comments

Comments
 (0)