Skip to content

Commit

Permalink
Add CD
Browse files Browse the repository at this point in the history
  • Loading branch information
Transfusion committed Jul 18, 2021
1 parent 918f860 commit a7cbd89
Showing 1 changed file with 62 additions and 0 deletions.
62 changes: 62 additions & 0 deletions .github/workflows/release_apk_aab.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
name: Assemble Release

on:
push:
tags:
- "release-*"

jobs:
build:

runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- uses: AdoptOpenJDK/install-jdk@v1
with:
version: '8'
architecture: x64
targets: 'JAVA_HOME'

- uses: actions/setup-node@v2
with:
node-version: '14'
- name: Setup Android SDK
uses: android-actions/setup-android@v2

- name: Install Bubblewrap
run: npm install -g @bubblewrap/cli

- name: Setup Bubblewrap
run: |
mkdir -p ~/.bubblewrap
echo "{\"jdkPath\":\"$JAVA_HOME\",\"androidSdkPath\":\"$ANDROID_SDK_ROOT\"}" > ~/.bubblewrap/config.json
bubblewrap doctor
- name: Load release keystore
run: |
if [[ -n "${{ secrets.RELEASE_KEYSTORE_BASE64 }}" ]]; then
echo "${{ secrets.RELEASE_KEYSTORE_BASE64 }}" | base64 -d > ~/android.keystore
fi
- name: Grant execute permission for gradlew
run: chmod +x gradlew

- name: Build
env:
BUBBLEWRAP_KEYSTORE_PASSWORD: ${{ secrets.BUBBLEWRAP_KEYSTORE_PASSWORD }}
BUBBLEWRAP_KEY_PASSWORD: ${{ secrets.BUBBLEWRAP_KEY_PASSWORD }}
run: |
bubblewrap build --signingKeyPath=$HOME/android.keystore --signingKeyAlias=android
- name: Release
uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/')
with:
files: |
app-release-bundle.aab
app-release-signed.apk
app-release-signed.apk.idsig
app-release-unsigned-aligned.apk
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}

0 comments on commit a7cbd89

Please sign in to comment.