Skip to content

Geometric Icon Provider #1

Geometric Icon Provider

Geometric Icon Provider #1

Workflow file for this run

name: Geometric Icon Provider push CI
on:
push:
branches:
- main
tags:
- v*
jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Gradle Wrapper
uses: gradle/actions/wrapper-validation@v3
- name: Setup Android SDK
run: |
${ANDROID_SDK_ROOT}/cmdline-tools/latest/bin/sdkmanager "build-tools;29.0.3"
- name: Set up JDK
uses: actions/setup-java@v4
with:
java-version: 17
distribution: adopt
- name: Set up gradle
uses: gradle/actions/setup-gradle@v3
- uses: gradle/actions/setup-gradle@v3
with:
arguments: assembleRelease
- name: Save version tag in env
if: startsWith(github.ref, 'refs/tags/') && github.repository == 'breezy-weather/geometric-icon-provider'
run: |
set -x
echo "VERSION_TAG=${GITHUB_REF/refs\/tags\//}" >> $GITHUB_ENV
- name: Sign APK
if: startsWith(github.ref, 'refs/tags/') && github.repository == 'breezy-weather/geometric-icon-provider'
uses: r0adkll/sign-android-release@v1
with:
releaseDirectory: app/build/outputs/apk/release
signingKeyBase64: ${{ secrets.SIGNING_KEY }}
alias: ${{ secrets.ALIAS }}
keyStorePassword: ${{ secrets.KEY_STORE_PASSWORD }}
keyPassword: ${{ secrets.KEY_PASSWORD }}
- name: Prepare APKs with checksums
if: startsWith(github.ref, 'refs/tags/') && github.repository == 'breezy-weather/geometric-icon-provider'
run: |
set -e
mv app/build/outputs/apk/release/app-release-unsigned-signed.apk geometric-icon-provider-${{ env.VERSION_TAG }}.apk
sha256=`sha256sum geometric-icon-provider-${{ env.VERSION_TAG }}.apk | awk '{ print $1 }'`
echo "APK_SHA256=$sha256" >> $GITHUB_ENV
- name: Create release
if: startsWith(github.ref, 'refs/tags/') && github.repository == 'breezy-weather/geometric-icon-provider'
uses: softprops/action-gh-release@v1
with:
tag_name: ${{ env.VERSION_TAG }}
name: Geometric Icon Provider ${{ env.VERSION_TAG }}
body: |
---
### Checksum
${{ env.APK_SHA256 }}
files: |
geometric-icon-provider-${{ env.VERSION_TAG }}.apk
draft: true
prerelease: false