-
Notifications
You must be signed in to change notification settings - Fork 4
97 lines (82 loc) · 3.23 KB
/
release-android.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
name: Release Android
on:
push:
tags:
- 'v[0-9]+.[0-9]+.[0-9]+'
- 'v[0-9]+.[0-9]+.[0-9]+-RC*'
jobs:
deploy:
name: Deploy Android Release
runs-on: ubuntu-latest
steps:
- name: Checkout 🛎
uses: actions/checkout@v3
- name: Setup JDK 11 🔧
uses: actions/setup-java@v3
with:
distribution: "zulu"
java-version: 11
- name: Setup Android SDK 🔧
uses: android-actions/setup-android@v2
- name: Setup ruby 🔧
uses: ruby/setup-ruby@v1
with:
ruby-version: '3.0'
bundler-cache: true
- name: Setup Node.js 🔧
uses: actions/setup-node@v3
with:
node-version: "18.x"
cache: 'yarn'
cache-dependency-path: |
yarn.lock
- name: Setup Gradle cache 🗄
uses: actions/cache@v3
with:
path: |
~/.gradle/caches
~/.gradle/wrapper
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*', '**/gradle-wrapper.properties') }}
restore-keys: |
${{ runner.os }}-gradle-
- name: Get version info ⚙
id: version-info
run: bundle exec fastlane common populate_github_env
- name: Install yarn dependencies 🔨
run: yarn install --immutable
- name: Expand secrets 🔨
run: bundler exec fastlane common expand_secrets
env:
ENV_WALLET_CONNECT_PROJECT_ID: ${{ secrets.ENV_WALLET_CONNECT_PROJECT_ID }}
ENV_WEB3_AUTH_CLIENT_ID_MAINNET: ${{ secrets.ENV_WEB3_AUTH_CLIENT_ID_MAINNET }}
ENV_POSTHOG_API_KEY: ${{ secrets.ENV_POSTHOG_API_KEY }}
ENV_SENTRY_AUTH_TOKEN: ${{ secrets.ENV_SENTRY_AUTH_TOKEN }}
ANDROID_GOOGLE_SERVICES_JSON: ${{ secrets.ANDROID_GOOGLE_SERVICES_JSON }}
ANDROID_BRANCH_KEYS: ${{ secrets.ANDROID_BRANCH_KEYS }}
- name: Build bundle 🔨
run: bundle exec fastlane android build_bundle
env:
ANDROID_KEYSTORE_BASE64: ${{ secrets.ANDROID_KEYSTORE_BASE64 }}
ANDROID_SIGNING_STORE_PASSWORD: ${{ secrets.ANDROID_SIGNING_STORE_PASSWORD }}
ANDROID_SIGNING_ALIAS: ${{ secrets.ANDROID_SIGNING_ALIAS }}
ANDROID_SIGNING_KEY_PASSWORD: ${{ secrets.ANDROID_SIGNING_KEY_PASSWORD }}
- name: Build apk 🔨
run: bundle exec fastlane android build_apk
env:
ANDROID_KEYSTORE_BASE64: ${{ secrets.ANDROID_KEYSTORE_BASE64 }}
ANDROID_SIGNING_STORE_PASSWORD: ${{ secrets.ANDROID_SIGNING_STORE_PASSWORD }}
ANDROID_SIGNING_ALIAS: ${{ secrets.ANDROID_SIGNING_ALIAS }}
ANDROID_SIGNING_KEY_PASSWORD: ${{ secrets.ANDROID_SIGNING_KEY_PASSWORD }}
- name: Deploy on Play Store 🚀
run: bundle exec fastlane android deploy_bundle
env:
PLAYSTORE_JSON_KEY: ${{ secrets.PLAYSTORE_JSON_KEY }}
- name: Upload apks to release 🚀
uses: svenstaro/upload-release-action@v2
with:
tag: ${{ github.ref }}
repo_token: ${{ secrets.GITHUB_TOKEN }}
file_glob: true
file: android/app/build/outputs/apk/release/*.apk
overwrite: true
prerelease: ${{ steps.version-info.outputs.IS_INTERNAL_RELEASE }}