From d18c87480f319296080fc516cf24093aa3b90aa1 Mon Sep 17 00:00:00 2001 From: Blanca Macazaga Date: Sun, 6 Oct 2024 19:37:31 +0200 Subject: [PATCH] Set test job conditions --- .github/workflows/c-cpp.yml | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/.github/workflows/c-cpp.yml b/.github/workflows/c-cpp.yml index 831be2c..0ec908f 100644 --- a/.github/workflows/c-cpp.yml +++ b/.github/workflows/c-cpp.yml @@ -11,11 +11,11 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - os: [ubuntu-latest] + os: [ubuntu-latest, windows-latest] #ubuntu-latest, macos-latest, windows-latest] include: - # - os: windows-latest - # triplet: x64-windows + - os: windows-latest + triplet: x64-windows - os: ubuntu-latest triplet: x64-linux # - os: macos-latest @@ -103,11 +103,11 @@ jobs: runs-on: ${{ matrix.os }} strategy: matrix: - os: [ubuntu-latest] + os: [ubuntu-latest, windows-latest] #ubuntu-latest, macos-latest, windows-latest] include: - # - os: windows-latest - # triplet: x64-windows + - os: windows-latest + triplet: x64-windows - os: ubuntu-latest triplet: x64-linux # - os: macos-latest @@ -115,6 +115,8 @@ jobs: continue-on-error: true + if: github.event_name == 'pull_request' || (github.event_name == 'push' && github.ref == 'refs/heads/main') + steps: - name: Set environment variable in lowercase letters run: echo "CURRENT_OS=$(echo $RUNNER_OS | tr '[:upper:]' '[:lower:]')" >> $GITHUB_ENV