Try to change CI/CD to build out both versions and upload #680
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Android Build SDK | |
on: | |
pull_request | |
# release: | |
# types: [released] | |
jobs: | |
install-and-test: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Use Node.js 16.x | |
uses: actions/setup-node@v1 | |
with: | |
node-version: 16.x | |
- name: Install dependencies | |
run: yarn | |
- name: Test and Lint | |
run: | | |
yarn ganache & | |
yarn test | |
yarn lint | |
build-android-eoa: | |
needs: install-and-test | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Use Node.js 16.x | |
uses: actions/setup-node@v1 | |
with: | |
node-version: 16.x | |
- name: Install dependencies | |
run: yarn | |
- name: Build Android Release | |
run: | | |
cd android | |
./gradlew app:assembleRelease | |
- name: Upload Artifact | |
uses: actions/upload-artifact@v3 | |
with: | |
name: app-release-eoa.apk | |
path: android/app/build/outputs/apk/release/app-release.apk | |
build-android-relay: | |
needs: install-and-test | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Use Node.js 16.x | |
uses: actions/setup-node@v1 | |
with: | |
node-version: 16.x | |
- name: Overwrite USE_RELAY env variable | |
run: echo "USE_RELAY=true" >> $GITHUB_ENV | |
- name: Install dependencies | |
run: yarn | |
- name: Build Android Release | |
run: | | |
cd android | |
./gradlew app:assembleRelease | |
- name: Upload Artifact | |
uses: actions/upload-artifact@v3 | |
with: | |
name: app-release-eoa.apk | |
path: android/app/build/outputs/apk/release/app-release.apk |