From acf401bca1b633f7a0da20ea0f4cb88a7450f454 Mon Sep 17 00:00:00 2001 From: Eli Bosley Date: Tue, 16 Dec 2025 11:48:54 -0500 Subject: [PATCH 1/2] chore(ci): refactor GitHub Actions workflow to streamline release process - Moved the 'release-please' job to run independently and added it as a dependency for the 'test-api' and 'build-plugin-staging-pr' jobs. - Updated permissions and checkout steps for the 'release-please' job to ensure proper execution on main branch pushes. - Enhanced workflow structure for better clarity and maintainability. --- .github/workflows/main.yml | 44 ++++++++++++++++++-------------------- 1 file changed, 21 insertions(+), 23 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index ac5563bddb..ef8a620916 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -15,12 +15,32 @@ concurrency: cancel-in-progress: ${{ github.event_name == 'pull_request' }} jobs: + release-please: + name: Release Please + runs-on: ubuntu-latest + if: github.event_name == 'push' && github.ref == 'refs/heads/main' + permissions: + contents: write + pull-requests: write + steps: + - name: Checkout + uses: actions/checkout@v6 + with: + fetch-depth: 0 + + - id: release + uses: googleapis/release-please-action@v4 + outputs: + releases_created: ${{ steps.release.outputs.releases_created || 'false' }} + tag_name: ${{ steps.release.outputs.tag_name || '' }} + test-api: name: Test API defaults: run: working-directory: api runs-on: ubuntu-latest + needs: release-please steps: - name: Checkout repo uses: actions/checkout@v6 @@ -164,32 +184,10 @@ jobs: VITE_CALLBACK_KEY: ${{ secrets.VITE_CALLBACK_KEY }} UNRAID_BOT_GITHUB_ADMIN_TOKEN: ${{ secrets.UNRAID_BOT_GITHUB_ADMIN_TOKEN }} - release-please: - name: Release Please - runs-on: ubuntu-latest - # Only run on pushes to main AND after tests pass - if: github.event_name == 'push' && github.ref == 'refs/heads/main' - needs: - - test-api - - build-artifacts - permissions: - contents: write - pull-requests: write - steps: - - name: Checkout - uses: actions/checkout@v6 - with: - fetch-depth: 0 - - - id: release - uses: googleapis/release-please-action@v4 - outputs: - releases_created: ${{ steps.release.outputs.releases_created || 'false' }} - tag_name: ${{ steps.release.outputs.tag_name || '' }} - build-plugin-staging-pr: name: Build and Deploy Plugin needs: + - release-please - build-artifacts - test-api uses: ./.github/workflows/build-plugin.yml From 088f239e81b632e9526e23689fd1d0aeb1221ee2 Mon Sep 17 00:00:00 2001 From: Eli Bosley Date: Tue, 16 Dec 2025 11:59:13 -0500 Subject: [PATCH 2/2] chore(ci): remove 'release-please' dependency from 'build-plugin-staging-pr' job in workflow --- .github/workflows/main.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index ef8a620916..5d119ab8bf 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -187,7 +187,6 @@ jobs: build-plugin-staging-pr: name: Build and Deploy Plugin needs: - - release-please - build-artifacts - test-api uses: ./.github/workflows/build-plugin.yml