compose-lobsters/.github/workflows/release.yml
renovate[bot] 1b1984064c
chore(deps): update gradle/gradle-build-action action to v2.8.1 (#399)
[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Type | Update | Change |
|---|---|---|---|
|
[gradle/gradle-build-action](https://togithub.com/gradle/gradle-build-action)
| action | patch | `v2.8.0` -> `v2.8.1` |

---

### Release Notes

<details>
<summary>gradle/gradle-build-action
(gradle/gradle-build-action)</summary>

###
[`v2.8.1`](https://togithub.com/gradle/gradle-build-action/compare/v2.8.0...v2.8.1)

[Compare
Source](https://togithub.com/gradle/gradle-build-action/compare/v2.8.0...v2.8.1)

</details>

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined),
Automerge - At any time (no schedule defined).

🚦 **Automerge**: Enabled.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box

---

This PR has been generated by [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View
repository job log
[here](https://developer.mend.io/github/msfjarvis/compose-lobsters).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzNi45Ny4xIiwidXBkYXRlZEluVmVyIjoiMzYuOTcuMSIsInRhcmdldEJyYW5jaCI6Im1haW4ifQ==-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2023-09-25 19:09:16 +00:00

124 lines
4 KiB
YAML

name: Release to Google Play
on:
workflow_dispatch:
inputs:
inAppUpdatePriority:
description: 'In app update priority (0-5)'
type: number
default: "0"
required: false
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
jobs:
publish-google-play-release:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@8ade135a41bc03ea155e62e844d188df1ea18608 # v4.1.0
with:
token: ${{ secrets.POST_RELEASE_GH_TOKEN }}
fetch-depth: 0
- name: Set up JDK
uses: actions/setup-java@0ab4596768b603586c0de567f2430c30f5b0d2b0 # v3.13.0
with:
distribution: temurin
java-version: 18
- name: Set up Git author
shell: bash
run: |
git config user.name "GitHub Actions"
git config user.email noreply@github.com
- name: Setup Gradle caching
uses: gradle/gradle-build-action@b5126f31dbc19dd434c3269bf8c28c315e121da2 # v2.8.1
with:
gradle-home-cache-cleanup: true
cache-read-only: true
- name: Decrypt secrets
run: |
./scripts/setup-age.sh
./scripts/signing-setup.sh "$AGE_SECRET_KEY"
env:
AGE_SECRET_KEY: ${{ secrets.AGE_SECRET_KEY }}
- name: Get current version
shell: bash
run: |
./gradlew -q --no-configuration-cache clearPreRelease
VERSION="$(tail -n1 android/version.properties | cut -d = -f 2)"
echo VERSION="${VERSION}" >> $GITHUB_ENV
- name: Update changelog
uses: msfjarvis/keep-a-changelog-new-release@bf43ae42f4e42f137572950af426efcf6e777207 # 2.1.0
with:
tag: v${{ env.VERSION }}
version: ${{ env.VERSION }}
- name: Commit changes
shell: bash
run: |
git commit -am 'feat(release): bump version'
- name: Build release assets
shell: bash
env:
SENTRY_DSN: ${{ secrets.SENTRY_DSN }}
SENTRY_AUTH_TOKEN: ${{ secrets.SENTRY_AUTH_TOKEN }}
run: |
./gradlew --no-configuration-cache collectReleaseApks collectReleaseBundle -PsentryUploadMappings
- name: Clean secrets
run: scripts/signing-cleanup.sh
- name: Get changelog entry
id: changelog_reader
uses: mindsers/changelog-reader-action@b97ce03a10d9bdbb07beb491c76a5a01d78cd3ef # v2.2.2
with:
version: ${{ env.VERSION }}
path: ./CHANGELOG.md
- name: Write release notes file
shell: bash
env:
CHANGELOG: ${{ steps.changelog_reader.outputs.changes }}
run: |
mkdir -p distribution/whatsnew
printf '## Changelog\n\n' > distribution/whatsnew/whatsnew-en-GB
printf '%s' "${CHANGELOG}" >> distribution/whatsnew/whatsnew-en-GB
- name: Publish bundle to Google Play
uses: r0adkll/upload-google-play@9cf8fd30c9e616ec761db3b9abb2b0f15842ce58 # v1.1.2
with:
mappingFile: android/bundle/mapping.txt
packageName: dev.msfjarvis.claw.android
releaseFiles: android/bundle/*.aab
serviceAccountJsonPlainText: ${{ secrets.SERVICE_ACCOUNT_JSON }}
status: completed
track: production
whatsNewDirectory: distribution/whatsnew
inAppUpdatePriority: ${{ inputs.inAppUpdatePriority }}
- name: Post-release work
shell: bash
env:
GITHUB_TOKEN: ${{ secrets.POST_RELEASE_GH_TOKEN }}
run: |
# Tag the current version
git tag "v${VERSION}" -F distribution/whatsnew/whatsnew-en-GB
# Push the tag to GitHub
git push origin "v${VERSION}"
# Create a GitHub release
gh release create "v${VERSION}" --notes-file distribution/whatsnew/whatsnew-en-GB --title "v${VERSION}" ./android/apk/*.apk ./android/bundle/*.aab
# Start the next development iteration
./gradlew -q --no-configuration-cache bumpSnapshot
truncate -s 0 distribution/whatsnew/whatsnew-en-GB # Clear changelog
git commit -am 'feat(release): start next development iteration'
git push -u origin