Skip to content

Merge pull request #291 from devgianlu/dependabot/gradle/com.google.g… #467

Merge pull request #291 from devgianlu/dependabot/gradle/com.google.g…

Merge pull request #291 from devgianlu/dependabot/gradle/com.google.g… #467

Workflow file for this run

name: Android CI
on:
push:
branches: [ master ]
tags:
- 'v*'
pull_request:
branches: [ master ]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
with:
submodules: recursive
- uses: actions/setup-java@v2
with:
distribution: 'adopt'
java-version: '17'
- name: Grant execute permission to scripts
run: chmod +x gradlew .github/decrypt_secrets.sh
- name: Decrypt GPG secrets
if: ${{ !startsWith(github.ref, 'refs/pull') }}
run: .github/decrypt_secrets.sh
env:
SECRETS_GPG_PASS: ${{ secrets.SECRETS_GPG_PASS }}
- name: Build with Gradle
if: ${{ !startsWith(github.ref, 'refs/tags/v') }}
run: ./gradlew connectedCheck --no-daemon
- name: Publish with Gradle
if: ${{ startsWith(github.ref, 'refs/tags/v') }}
run: ./gradlew assembleRelease publishApps --no-daemon
env:
JAVA_OPTS: -Xmx2g -XX:MaxMetaspaceSize=512m
KEYSTORE_STORE_PASS: ${{ secrets.KEYSTORE_STORE_PASS }}
KEYSTORE_KEY_ALIAS: gianlu
KEYSTORE_KEY_PASS: ${{ secrets.KEYSTORE_KEY_PASS }}
- name: Create release
if: ${{ startsWith(github.ref, 'refs/tags/v') }}
id: create_release
uses: actions/create-release@v1
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
tag_name: ${{ github.ref }}
release_name: ${{ github.ref }}
body_path: app/src/main/play/release-notes/en-GB/production.txt
draft: true
prerelease: false