From 2324d8354fa71f34f025d20eac92b08f63f9d6aa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Martin=20Storsj=C3=B6?= Date: Tue, 29 Jul 2025 16:54:08 +0300 Subject: [PATCH] github: Simplify running the msvcrt workflow on push, for testing Only pick parameters from "inputs" if we were invoked through a "workflow_dispatch" event. --- .github/workflows/msvcrt.yml | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/.github/workflows/msvcrt.yml b/.github/workflows/msvcrt.yml index 99d9cfc..a2edada 100644 --- a/.github/workflows/msvcrt.yml +++ b/.github/workflows/msvcrt.yml @@ -31,8 +31,8 @@ jobs: with: workflow: build.yml workflow_conclusion: success - ref: ${{inputs.ref}} - event: push + ref: ${{github.event_name == 'workflow_dispatch' && inputs.ref || 'master'}} + event: ${{github.event_name == 'workflow_dispatch' && 'push' || 'schedule'}} name: parameters - name: Get build parameters id: get-parameters @@ -47,14 +47,14 @@ jobs: steps: - uses: actions/checkout@v4 with: - ref: ${{inputs.ref}} + ref: ${{github.event_name == 'workflow_dispatch' && inputs.ref || 'master'}} - name: Download toolchain uses: dawidd6/action-download-artifact@v10 with: workflow: build.yml workflow_conclusion: success - ref: ${{inputs.ref}} - event: push + ref: ${{github.event_name == 'workflow_dispatch' && inputs.ref || 'master'}} + event: ${{github.event_name == 'workflow_dispatch' && 'push' || 'schedule'}} name: linux-ucrt-x86_64-toolchain - name: Unpack original toolchain run: | @@ -105,14 +105,14 @@ jobs: echo /opt/llvm-mingw/bin >> $GITHUB_PATH - uses: actions/checkout@v4 with: - ref: ${{inputs.ref}} + ref: ${{github.event_name == 'workflow_dispatch' && inputs.ref || 'master'}} - name: Download profile uses: dawidd6/action-download-artifact@v10 with: workflow: build.yml workflow_conclusion: success - ref: ${{inputs.ref}} - event: push + ref: ${{github.event_name == 'workflow_dispatch' && inputs.ref || 'master'}} + event: ${{github.event_name == 'workflow_dispatch' && 'push' || 'schedule'}} name: profile - name: Build env: @@ -169,14 +169,14 @@ jobs: echo /llvm-mingw/bin >> $GITHUB_PATH - uses: actions/checkout@v4 with: - ref: ${{inputs.ref}} + ref: ${{github.event_name == 'workflow_dispatch' && inputs.ref || 'master'}} - name: Run tests run: | ./run-tests.sh /llvm-mingw ./run-lldb-tests.sh /llvm-mingw upload: - if: ${{inputs.upload}} + if: ${{github.event_name == 'workflow_dispatch' && inputs.upload}} permissions: contents: write needs: [linux-msvcrt, linux-cross-windows, test-toolchain, prepare]