From 8904dc83b4428f564f016d2c1a278ce4db8a18e0 Mon Sep 17 00:00:00 2001 From: James Benton Date: Wed, 25 Mar 2026 09:31:28 +0000 Subject: [PATCH 1/4] Only run Upload Artifact on push to main, not on pull requests. Also update checkout action due to github deprecating old versions of node. --- .github/workflows/build.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 44708ee1..2e3e7df6 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -14,7 +14,7 @@ jobs: - windows-latest steps: - name: 'Checkout' - uses: actions/checkout@v2 + uses: actions/checkout@v6 - uses: actions-rs/toolchain@v1 with: profile: minimal @@ -31,13 +31,13 @@ jobs: command: build args: --release - name: 'Upload Artifact (Windows)' - if: matrix.os == 'windows-latest' + if: matrix.os == 'windows-latest' && github.ref == 'refs/heads/main' uses: actions/upload-artifact@v4 with: name: rose-offline-client-${{ matrix.os }} path: target/release/rose-offline-client.exe - name: 'Upload Artifact (Ubuntu, MacOS)' - if: matrix.os != 'windows-latest' + if: matrix.os != 'windows-latest' && github.ref == 'refs/heads/main' uses: actions/upload-artifact@v4 with: name: rose-offline-client-${{ matrix.os }} From 7557da387714878cee890810a3ce6a07528ed325 Mon Sep 17 00:00:00 2001 From: James Benton Date: Wed, 25 Mar 2026 09:36:14 +0000 Subject: [PATCH 2/4] Only run on push to main, not push to every branch. --- .github/workflows/build.yml | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 2e3e7df6..a4e1cef0 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1,4 +1,7 @@ -on: [push, pull_request] +on: + push: + branches: [main] + pull_request: {} name: Build From 6585ddf86311a77bef7d4e978e54e8b202bc3a07 Mon Sep 17 00:00:00 2001 From: James Benton Date: Wed, 25 Mar 2026 09:39:19 +0000 Subject: [PATCH 3/4] actually nvm lets keep artifacts for all builds --- .github/workflows/build.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index a4e1cef0..3e0936f1 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -34,13 +34,13 @@ jobs: command: build args: --release - name: 'Upload Artifact (Windows)' - if: matrix.os == 'windows-latest' && github.ref == 'refs/heads/main' + if: matrix.os == 'windows-latest' uses: actions/upload-artifact@v4 with: name: rose-offline-client-${{ matrix.os }} path: target/release/rose-offline-client.exe - name: 'Upload Artifact (Ubuntu, MacOS)' - if: matrix.os != 'windows-latest' && github.ref == 'refs/heads/main' + if: matrix.os != 'windows-latest' uses: actions/upload-artifact@v4 with: name: rose-offline-client-${{ matrix.os }} From 544ff4a0e3ddea7702b4fa00a67963642de01066 Mon Sep 17 00:00:00 2001 From: James Benton Date: Wed, 25 Mar 2026 09:40:39 +0000 Subject: [PATCH 4/4] add cancel-in-progress to non main builds --- .github/workflows/build.yml | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index 3e0936f1..509f278c 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -1,10 +1,14 @@ +name: Build + +concurrency: + group: ${{ github.workflow }}-${{ github.ref }} + cancel-in-progress: ${{ github.ref != 'refs/heads/main' }} + on: push: branches: [main] pull_request: {} -name: Build - jobs: release: name: Build