Unverified Commit d3c10c36 authored by Ricki Hirner's avatar Ricki Hirner
Browse files

CI: create Github release for new tags

parent f37f3e51
blank_issues_enabled: false
contact_links:
- name: DAVx⁵ Community Forum
url: https://www.davx5.com/forums
about: Please use our forum for questions, support, suggestions etc.
name: Create release
on:
push:
tags:
- v*
jobs:
build:
name: Create release
permissions:
contents: write
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
submodules: true
- uses: actions/setup-java@v2
with:
distribution: 'temurin'
java-version: 11
cache: 'gradle'
- uses: gradle/wrapper-validation-action@v1
- name: Prepare keystore
run: echo ${{ secrets.android_keystore_base64 }} | base64 -d >$GITHUB_WORKSPACE/keystore.jks
- name: Build signed package
run: ./gradlew app:assembleRelease
env:
ANDROID_KEYSTORE: ${{ github.workspace }}/keystore.jks
ANDROID_KEYSTORE_PASSWORD: ${{ secrets.android_keystore_password }}
ANDROID_KEY_ALIAS: ${{ secrets.android_key_alias }}
ANDROID_KEY_PASSWORD: ${{ secrets.android_key_password }}
- name: Create Github release
uses: softprops/action-gh-release@v0.1.14
with:
prerelease: ${{ contains(github.ref_name, '-alpha') || contains(github.ref_name, '-beta') || contains(github.ref_name, '-rc') }}
files: app/build/outputs/apk/standard/release/*.apk
fail_on_unmatched_files: true
......@@ -18,6 +18,8 @@ android {
versionName '4.2.1'
buildConfigField "long", "buildTime", System.currentTimeMillis() + "L"
setProperty "archivesBaseName", "davx5-ose-" + getVersionName()
minSdkVersion 21 // Android 5
targetSdkVersion 32 // Android 12
......@@ -60,6 +62,15 @@ android {
androidTest.assets.srcDirs += files("$projectDir/schemas".toString())
}
signingConfigs {
bitfire {
storeFile file(System.getenv("ANDROID_KEYSTORE") ?: "/dev/null")
storePassword System.getenv("ANDROID_KEYSTORE_PASSWORD")
keyAlias System.getenv("ANDROID_KEY_ALIAS")
keyPassword System.getenv("ANDROID_KEY_PASSWORD")
}
}
buildTypes {
debug {
}
......@@ -68,6 +79,8 @@ android {
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules-release.pro'
shrinkResources true
signingConfig signingConfigs.bitfire
}
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment