fix debug arfifact name #31
Workflow file for this run
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 publish | |
on: | |
push: | |
tags: | |
- 'v*.*.*' | |
jobs: | |
build-and-release: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check out code | |
uses: actions/checkout@v2 | |
- name: Set up JDK 17 | |
uses: actions/setup-java@v2 | |
with: | |
java-version: '17' | |
distribution: 'adopt' | |
- name: Cache Gradle and wrapper | |
uses: actions/cache@v2 | |
with: | |
path: | | |
~/.gradle/caches | |
~/.gradle/wrapper | |
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle*') }} | |
- name: Set up env variables | |
run: | | |
echo "RELEASE_VERSION=${GITHUB_REF#refs/tags/v}" >> $GITHUB_ENV | |
echo "RELEASE_ARTIFACT=simpleBleClient_release_${GITHUB_REF#refs/tags/v}.aar" >> $GITHUB_ENV | |
echo "DEBUG_ARTIFACT=simpleBleClient_debug_${GITHUB_REF#refs/tags/v}.aar" >> $GITHUB_ENV | |
echo "KEYSTORE_PATH=${{ secrets.KEYSTORE_PATH }}" >> $GITHUB_ENV | |
echo "KEY_ALIAS=${{ secrets.KEY_ALIAS }}" >> $GITHUB_ENV | |
echo "KEYSTORE_PASSWORD=${{ secrets.KEYSTORE_PASSWORD }}" >> $GITHUB_ENV | |
echo "GITHUB_TOKEN=${{ secrets.GITHUB_TOKEN }}" >> $GITHUB_ENV | |
- name: Decode Keystore | |
run: pwd; echo ${{ secrets.ENCODED_KEYSTORE }} | base64 -d > ${{ secrets.KEYSTORE_NAME }} | |
- name: Build and Sign AAR | |
run: ./gradlew assembleRelease | |
- name: Create Github Release | |
uses: softprops/action-gh-release@v1 | |
with: | |
generate_release_notes: true | |
prerelease: true | |
draft: false | |
files: | | |
simpleBleClient/build/outputs/aar/${{ env.RELEASE_ARTIFACT }} | |
simpleBleClient/build/outputs/aar/${{ env.DEBUG_ARTIFACT }} | |
LICENSE |