fix(ci): align with time-until eas init + local eas build flow
This commit is contained in:
@@ -9,13 +9,12 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: 🏗 Setup repo
|
- name: 🏗 Setup repo
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v2
|
||||||
|
|
||||||
- name: 🏗 Setup Node
|
- name: 🏗 Setup Node
|
||||||
uses: actions/setup-node@v4
|
uses: actions/setup-node@v2
|
||||||
with:
|
with:
|
||||||
node-version: 22
|
node-version: 22
|
||||||
cache: pnpm
|
|
||||||
|
|
||||||
- name: 🏗 Setup pnpm
|
- name: 🏗 Setup pnpm
|
||||||
uses: pnpm/action-setup@v4
|
uses: pnpm/action-setup@v4
|
||||||
@@ -31,22 +30,32 @@ jobs:
|
|||||||
- name: 🏗 Setup Android SDK
|
- name: 🏗 Setup Android SDK
|
||||||
uses: android-actions/setup-android@v3
|
uses: android-actions/setup-android@v3
|
||||||
|
|
||||||
|
- name: 🏗 Setup Expo and EAS
|
||||||
|
uses: expo/expo-github-action@v8
|
||||||
|
with:
|
||||||
|
token: ${{ secrets.EXPO_TOKEN }}
|
||||||
|
eas-version: latest
|
||||||
|
packager: pnpm
|
||||||
|
|
||||||
- name: 📦 Install dependencies
|
- name: 📦 Install dependencies
|
||||||
run: pnpm install --frozen-lockfile
|
run: pnpm install
|
||||||
|
|
||||||
- name: 🧱 Generate native Android project
|
- name: 🧩 Init EAS project
|
||||||
run: npx expo prebuild --platform android --non-interactive
|
run: eas init --non-interactive
|
||||||
|
|
||||||
- name: 👷 Build release APK
|
- name: 👷 Build app
|
||||||
run: |
|
run: |
|
||||||
cd android
|
eas build --local \
|
||||||
./gradlew assembleRelease --no-daemon
|
--non-interactive \
|
||||||
|
--output=./app-build \
|
||||||
|
--platform=android \
|
||||||
|
--profile=preview
|
||||||
|
|
||||||
- name: 📝 Rename build to APK
|
- name: 📝 Rename build to APK
|
||||||
run: cp android/app/build/outputs/apk/release/app-release.apk luggage-list-release.apk
|
run: mv app-build luggage-list-release.apk
|
||||||
|
|
||||||
- name: 📤 Upload build artifact
|
- name: 📤 Upload build artifact
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: luggage-list-android-preview-build
|
name: luggage-list-android-preview-build
|
||||||
path: luggage-list-release.apk
|
path: luggage-list-release.apk
|
||||||
@@ -56,21 +65,27 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: 🏗 Setup repo
|
- name: 🏗 Setup repo
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v2
|
||||||
|
|
||||||
- name: 🏗 Setup Node
|
- name: 🏗 Setup Node
|
||||||
uses: actions/setup-node@v4
|
uses: actions/setup-node@v2
|
||||||
with:
|
with:
|
||||||
node-version: 22
|
node-version: 22
|
||||||
cache: pnpm
|
|
||||||
|
|
||||||
- name: 🏗 Setup pnpm
|
- name: 🏗 Setup pnpm
|
||||||
uses: pnpm/action-setup@v4
|
uses: pnpm/action-setup@v4
|
||||||
with:
|
with:
|
||||||
version: latest
|
version: latest
|
||||||
|
|
||||||
|
- name: 🏗 Setup Expo and EAS
|
||||||
|
uses: expo/expo-github-action@v8
|
||||||
|
with:
|
||||||
|
token: ${{ secrets.EXPO_TOKEN }}
|
||||||
|
eas-version: latest
|
||||||
|
packager: pnpm
|
||||||
|
|
||||||
- name: 📦 Install dependencies
|
- name: 📦 Install dependencies
|
||||||
run: pnpm install --frozen-lockfile
|
run: pnpm install
|
||||||
|
|
||||||
- name: 👷 Build web
|
- name: 👷 Build web
|
||||||
run: npx expo export --platform web
|
run: npx expo export --platform web
|
||||||
@@ -79,7 +94,7 @@ jobs:
|
|||||||
run: cd dist && zip -r ../luggage-list-dist.zip .
|
run: cd dist && zip -r ../luggage-list-dist.zip .
|
||||||
|
|
||||||
- name: 📤 Upload build artifact
|
- name: 📤 Upload build artifact
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: luggage-list-web-build
|
name: luggage-list-web-build
|
||||||
path: luggage-list-dist.zip
|
path: luggage-list-dist.zip
|
||||||
@@ -90,15 +105,15 @@ jobs:
|
|||||||
needs: [build-android, build-web]
|
needs: [build-android, build-web]
|
||||||
steps:
|
steps:
|
||||||
- name: 🏗 Setup repo
|
- name: 🏗 Setup repo
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v2
|
||||||
|
|
||||||
- name: 📥 Download Android artifact
|
- name: 📥 Download Android artifact
|
||||||
uses: actions/download-artifact@v4
|
uses: actions/download-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: luggage-list-android-preview-build
|
name: luggage-list-android-preview-build
|
||||||
|
|
||||||
- name: 📥 Download Web artifact
|
- name: 📥 Download Web artifact
|
||||||
uses: actions/download-artifact@v4
|
uses: actions/download-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: luggage-list-web-build
|
name: luggage-list-web-build
|
||||||
|
|
||||||
|
|||||||
@@ -7,13 +7,12 @@ jobs:
|
|||||||
runs-on: ubuntu-latest
|
runs-on: ubuntu-latest
|
||||||
steps:
|
steps:
|
||||||
- name: 🏗 Setup repo
|
- name: 🏗 Setup repo
|
||||||
uses: actions/checkout@v4
|
uses: actions/checkout@v2
|
||||||
|
|
||||||
- name: 🏗 Setup Node
|
- name: 🏗 Setup Node
|
||||||
uses: actions/setup-node@v4
|
uses: actions/setup-node@v2
|
||||||
with:
|
with:
|
||||||
node-version: 22
|
node-version: 22
|
||||||
cache: pnpm
|
|
||||||
|
|
||||||
- name: 🏗 Setup pnpm
|
- name: 🏗 Setup pnpm
|
||||||
uses: pnpm/action-setup@v4
|
uses: pnpm/action-setup@v4
|
||||||
@@ -29,22 +28,32 @@ jobs:
|
|||||||
- name: 🏗 Setup Android SDK
|
- name: 🏗 Setup Android SDK
|
||||||
uses: android-actions/setup-android@v3
|
uses: android-actions/setup-android@v3
|
||||||
|
|
||||||
|
- name: 🏗 Setup Expo and EAS
|
||||||
|
uses: expo/expo-github-action@v8
|
||||||
|
with:
|
||||||
|
token: ${{ secrets.EXPO_TOKEN }}
|
||||||
|
eas-version: latest
|
||||||
|
packager: pnpm
|
||||||
|
|
||||||
- name: 📦 Install dependencies
|
- name: 📦 Install dependencies
|
||||||
run: pnpm install --frozen-lockfile
|
run: pnpm install
|
||||||
|
|
||||||
- name: 🧱 Generate native Android project
|
- name: 🧩 Init EAS project
|
||||||
run: npx expo prebuild --platform android --non-interactive
|
run: eas init --non-interactive
|
||||||
|
|
||||||
- name: 👷 Build release APK
|
- name: 👷 Build app
|
||||||
run: |
|
run: |
|
||||||
cd android
|
eas build --local \
|
||||||
./gradlew assembleRelease --no-daemon
|
--non-interactive \
|
||||||
|
--output=./app-build \
|
||||||
|
--platform=android \
|
||||||
|
--profile=preview
|
||||||
|
|
||||||
- name: 📝 Rename build to APK
|
- name: 📝 Rename build to APK
|
||||||
run: cp android/app/build/outputs/apk/release/app-release.apk luggage-list-manual.apk
|
run: mv app-build luggage-list-manual.apk
|
||||||
|
|
||||||
- name: 📤 Upload build artifact
|
- name: 📤 Upload build artifact
|
||||||
uses: actions/upload-artifact@v4
|
uses: actions/upload-artifact@v3
|
||||||
with:
|
with:
|
||||||
name: luggage-list-manual-apk-build
|
name: luggage-list-manual-apk-build
|
||||||
path: luggage-list-manual.apk
|
path: luggage-list-manual.apk
|
||||||
|
|||||||
@@ -29,5 +29,5 @@ npm run start
|
|||||||
Gitea workflows are in `.gitea/workflows`:
|
Gitea workflows are in `.gitea/workflows`:
|
||||||
|
|
||||||
- `dev.yml`: smoke check via `expo export --platform web` on non-main branches
|
- `dev.yml`: smoke check via `expo export --platform web` on non-main branches
|
||||||
- `ci.yml`: Android APK build via `expo prebuild` + Gradle, web bundle export, release tag/artifacts on `main`
|
- `ci.yml`: Android APK build via `eas init` + `eas build --local`, web bundle export, release tag/artifacts on `main`
|
||||||
- `manual-build.yml`: manual Android APK build via `expo prebuild` + Gradle
|
- `manual-build.yml`: manual Android APK build via `eas init` + `eas build --local`
|
||||||
|
|||||||
2
TODO.md
2
TODO.md
@@ -28,4 +28,4 @@
|
|||||||
- [x] Added trip deletion flow and confirmation
|
- [x] Added trip deletion flow and confirmation
|
||||||
- [x] Updated Gitea workflows/artifacts naming for Luggage List
|
- [x] Updated Gitea workflows/artifacts naming for Luggage List
|
||||||
- [x] Ran local web export smoke checks successfully
|
- [x] Ran local web export smoke checks successfully
|
||||||
- [x] Fixed CI build path to avoid EAS project init requirement (use expo prebuild + Gradle APK build)
|
- [x] Switched CI/manual APK workflow to run `eas init --non-interactive` before `eas build --local`
|
||||||
|
|||||||
Reference in New Issue
Block a user