|
1 |
| -name: Build And Upload APK |
| 1 | +name: Build and Deploy |
2 | 2 |
|
3 | 3 | on:
|
4 | 4 | push:
|
5 | 5 | branches:
|
6 | 6 | - master
|
7 | 7 |
|
8 |
| -jobs: |
9 |
| - build-and-upload: |
| 8 | +jobs: |
| 9 | + build-and-deploy: |
10 | 10 | runs-on: ubuntu-latest
|
11 | 11 |
|
12 | 12 | steps:
|
13 |
| - - name: Checkout the code |
14 |
| - uses: actions/checkout@v2 |
15 |
| - |
16 |
| - - name: Set up Node.js |
17 |
| - uses: actions/setup-node@v2 |
18 |
| - with: |
19 |
| - node-version: '16.x' |
20 |
| - |
21 |
| - - name: Install dependencies |
22 |
| - run: npm install |
23 |
| - |
24 |
| - - name: Authenticate with EAS |
25 |
| - run: | |
26 |
| - echo "{\"cli\": {\"username\": \"$EAS_USERNAME\",\"password\": \"$EAS_PASSWORD\"}}" > ~/.eas.json |
27 |
| - npx eas-cli login |
28 |
| - env: |
29 |
| - EAS_USERNAME: ${{ secrets.EAS_USERNAME }} |
30 |
| - EAS_PASSWORD: ${{ secrets.EAS_PASSWORD }} |
31 |
| - |
32 |
| - - name: Build the app |
33 |
| - run: | |
34 |
| - npx eas-cli build -p android |
35 |
| -
|
36 |
| - - name: Upload the APK to Uploadcare |
37 |
| - run: | |
38 |
| - curl -F "UPLOADCARE_PUB_KEY=${{ secrets.UPLOADCARE_PUB_KEY }}" \ |
39 |
| - -F "file=@./android/app/build/outputs/apk/release/app-release.apk" \ |
40 |
| - "https://upload.uploadcare.com/base/" |
| 13 | + - uses: actions/checkout@v2 |
| 14 | + |
| 15 | + - uses: actions/setup-node@v2 |
| 16 | + with: |
| 17 | + node-version: '16' |
| 18 | + |
| 19 | + - name: Log in to Expo |
| 20 | + uses: expo/expo-github-action@v5 |
| 21 | + with: |
| 22 | + expo-version: 3.x |
| 23 | + expo-username: ${{ secrets.EAS_USERNAME }} |
| 24 | + expo-password: ${{ secrets.EAS_PASSWORD }} |
| 25 | + |
| 26 | + - name: Install dependencies |
| 27 | + run: npm install |
| 28 | + |
| 29 | + - name: Build Android APK Bundle |
| 30 | + run: expo build:android |
| 31 | + |
| 32 | + - name: Upload the APK to Uploadcare |
| 33 | + run: | |
| 34 | + curl -F "UPLOADCARE_PUB_KEY=${{ secrets.UPLOADCARE_PUB_KEY }}" \ |
| 35 | + -F "file=@./android/app/build/outputs/apk/release/app-release.apk" \ |
| 36 | + "https://upload.uploadcare.com/base/" |
| 37 | +
|
0 commit comments