Skip to content

62.3.3

62.3.3 #111

Workflow file for this run

name: Release
on:
release:
types: [ published ]
defaults:
run:
shell: bash -l {0}
env:
flavour: oss
jobs:
Build:
name: Build
permissions:
statuses: write
pull-requests: write
contents: write
uses: ./.github/workflows/_build.yml
Deploy:
name: Deploy
runs-on: ubuntu-latest
environment: Publishing
needs: [Build]
timeout-minutes: 30
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up JDK
uses: actions/setup-java@v4
with:
java-version: '17'
distribution: 'adopt'
- name: Create Sonatype key
run: base64 -d <<< $SONATYPE_SINGING_KEY_BASE64 > sonatype.gpg
env:
SONATYPE_SINGING_KEY_BASE64: ${{ secrets.SONATYPE_SINGING_KEY_BASE64 }}
- name: Building release APK
run: |
openssl aes-256-cbc -K $KEYSTORE_DECRYPT_KEY -iv $KEYSTORE_DECRYPT_IV -in backpack.android.demo.key.enc -out backpack.android.demo.key -d;
./gradlew :app:assemble${{ env.flavour }}Release -PdisablePreDex
env:
KEYSTORE_PASSWORD: ${{ secrets.KEYSTORE_PASSWORD }}
KEYSTORE_ALIAS: ${{ secrets.KEYSTORE_ALIAS }}
KEYSTORE_ALIAS_PASSWORD: ${{ secrets.KEYSTORE_ALIAS_PASSWORD }}
MAPS_API_KEY: ${{ secrets.MAPS_API_KEY }}
KEYSTORE_DECRYPT_KEY: ${{ secrets.KEYSTORE_DECRYPT_KEY }}
KEYSTORE_DECRYPT_IV: ${{ secrets.KEYSTORE_DECRYPT_IV }}
- name: Build Dokka docs
run: ./gradlew dokkaHtmlMultiModule
- name: Publish artifacts
run: >
./gradlew checkMavenCredentials
publishMavenPublicationToSonatypeRepository
closeAndReleaseSonatypeStagingRepository
-Pversion=${{ github.event.release.tag_name }}
env:
SONATYPE_SINGING_KEY_ID: ${{ secrets.SONATYPE_SINGING_KEY_ID }}
SONATYPE_SINGING_KEY_PASSWORD: ${{ secrets.SONATYPE_SINGING_KEY_PASSWORD }}
SONATYPE_STAGING_PROFILE_ID: ${{ secrets.SONATYPE_STAGING_PROFILE_ID }}
OSSRH_USERNAME: ${{ secrets.OSSRH_USERNAME }}
OSSRH_PASSWORD: ${{ secrets.OSSRH_PASSWORD }}
- name: Remove Sonatype key
run: rm -rf sonatype.gpg
- name: Deploy Dokka docs
uses: peaceiris/actions-gh-pages@v4
with:
deploy_key: ${{ secrets.DOKKA_DEPLOY_KEY }}
publish_dir: dokka/
keep_files: true
external_repository: backpack/android
publish_branch: main
- name: Publish Release APK to AppCenter
uses: wzieba/AppCenter-Github-Action@v1.3.4
with:
appName: Backpack/Backpack-Android
token: ${{secrets.APP_CENTER_TOKEN}}
group: Everyone
file: app/build/outputs/apk/oss/release/app-${{ env.flavour }}-release.apk
releaseNotes: Version ${{github.event.release.tag_name}}
SupernovaPublish:
runs-on: ubuntu-latest
environment: Publishing
steps:
- name: Update Supernova docs
run: npx @supernovaio/cli publish-documentation --apiKey=${{ secrets.SUPERNOVA_API_KEY }} --designSystemId=${{ secrets.SUPERNOVA_DESIGN_SYSTEM_ID }}