From 7761d4daf1710c9573dc76c79633a55f68444a9b Mon Sep 17 00:00:00 2001 From: "personaclick-courier[bot]" <205635110+personaclick-courier[bot]@users.noreply.github.com> Date: Mon, 2 Jun 2025 06:09:10 +0000 Subject: [PATCH] feat: release --- .github/workflows/auto-merge-release-pr.yml | 18 ++++++++++++++++++ .github/workflows/auto-merge-sync-pr.yml | 18 ++++++++++++++++++ .github/workflows/publish.yaml | 4 ++-- .github/workflows/version.yaml | 17 +++++++++++++---- .releaserc.yml | 4 ++++ 5 files changed, 55 insertions(+), 6 deletions(-) create mode 100644 .github/workflows/auto-merge-release-pr.yml create mode 100644 .github/workflows/auto-merge-sync-pr.yml diff --git a/.github/workflows/auto-merge-release-pr.yml b/.github/workflows/auto-merge-release-pr.yml new file mode 100644 index 0000000..8d986a3 --- /dev/null +++ b/.github/workflows/auto-merge-release-pr.yml @@ -0,0 +1,18 @@ +name: Auto Merge Release PRs + +on: + pull_request: + types: [opened, synchronize] + branches: + - master + paths-ignore: + - ".github/**" + +jobs: + auto-merge: + if: startsWith(github.head_ref, 'release/') + uses: personaclick/workflow/.github/workflows/reusable-auto-merge-pr.yaml@master + secrets: + appSecret: ${{ secrets.VERSIONER_SECRET }} + with: + appId: ${{ vars.VERSIONER_ID }} diff --git a/.github/workflows/auto-merge-sync-pr.yml b/.github/workflows/auto-merge-sync-pr.yml new file mode 100644 index 0000000..7f5132c --- /dev/null +++ b/.github/workflows/auto-merge-sync-pr.yml @@ -0,0 +1,18 @@ +name: Auto Merge Sync PRs + +on: + pull_request: + types: [opened, synchronize] + branches: + - master + paths-ignore: + - ".github/**" + +jobs: + auto-merge: + if: startsWith(github.head_ref, 'sync/') + uses: personaclick/workflow/.github/workflows/reusable-auto-merge-pr.yaml@master + secrets: + appSecret: ${{ secrets.VERSIONER_SECRET }} + with: + appId: ${{ vars.VERSIONER_ID }} diff --git a/.github/workflows/publish.yaml b/.github/workflows/publish.yaml index e4d0926..604e234 100644 --- a/.github/workflows/publish.yaml +++ b/.github/workflows/publish.yaml @@ -13,12 +13,12 @@ jobs: if: github.event_name == 'workflow_dispatch' || (github.event_name == 'pull_request' && github.event.pull_request.merged == true && startsWith(github.event.pull_request.head.ref, 'release/')) uses: personaclick/workflow/.github/workflows/reusable-android-google-play-publish.yaml@7907f21814b2f998ffd80451754ce026e3553265 with: - githubAppId: ${{ vars.PERSONACLICK_COURIER_ID }} + githubAppId: ${{ vars.PUBLISHER_ID }} packageName: "personaClick.demo_shop" aabReleasePath: "app/build/outputs/bundle/prodRelease/app-prod-release.aab" propertiesFilePath: "version.properties" secrets: - GITHUB_APP_PRIVATE_KEY: ${{ secrets.PERSONACLICK_COURIER_SECRET }} + GITHUB_APP_PRIVATE_KEY: ${{ secrets.PUBLISHER_SECRET }} GOOGLE_SERVICES_FILE_AS_BASE64: ${{ secrets.GOOGLE_SERVICES_FILE_AS_BASE64 }} GOOGLE_PLAY_SIGNING_KEY_FILE_AS_BASE64: ${{ secrets.GOOGLE_PLAY_SIGNING_KEY_FILE_AS_BASE64 }} RELEASE_STORE_PASSWORD: ${{ secrets.RELEASE_STORE_PASSWORD }} diff --git a/.github/workflows/version.yaml b/.github/workflows/version.yaml index 34a0bcf..9fe1079 100644 --- a/.github/workflows/version.yaml +++ b/.github/workflows/version.yaml @@ -6,16 +6,25 @@ on: - master paths-ignore: - ".github/**" - - "version.properties" workflow_dispatch: jobs: + find-release-commit: + uses: personaclick/workflow/.github/workflows/reusable-release-commit-finder.yaml@master + secrets: + githubToken: ${{ secrets.GITHUB_TOKEN }} + bump-version: - if: github.event_name == 'workflow_dispatch' || (github.event_name == 'push' && !startsWith(github.event.pull_request.head.ref, 'release/')) + needs: find-release-commit + if: | + github.event_name == 'workflow_dispatch' || ( + github.event_name == 'push' && + needs.find-release-commit.outputs.hasCommit == 'false') uses: personaclick/workflow/.github/workflows/reusable-multiplatform-version-bump.yaml@master permissions: write-all secrets: - appSecret: ${{ secrets.PERSONACLICK_COURIER_SECRET }} + appSecret: ${{ secrets.VERSIONER_SECRET }} + githubToken: ${{ secrets.GITHUB_TOKEN }} with: - appId: ${{ vars.PERSONACLICK_COURIER_ID }} + appId: ${{ vars.VERSIONER_ID }} reviewerUsername: iwwwanow diff --git a/.releaserc.yml b/.releaserc.yml index 7051510..2a2f087 100644 --- a/.releaserc.yml +++ b/.releaserc.yml @@ -4,6 +4,10 @@ [ "@semantic-release/commit-analyzer", "@semantic-release/release-notes-generator", + [ + "@semantic-release/github", + { "successComment": false, "releasedLabels": false }, + ], [ "@semantic-release/git", {