From fee1da383bef47f7ef8f372bf9562c5f09b9478e Mon Sep 17 00:00:00 2001 From: Corentin Le Molgat Date: Mon, 10 Jul 2023 18:03:11 +0200 Subject: [PATCH] bazel(ci): Setup python version --- .github/workflows/amd64_linux_bazel.yml | 15 ++++++++++++--- .github/workflows/amd64_macos_bazel.yml | 11 +++++++++++ .github/workflows/amd64_windows_bazel.yml | 13 ++++++++++--- 3 files changed, 33 insertions(+), 6 deletions(-) diff --git a/.github/workflows/amd64_linux_bazel.yml b/.github/workflows/amd64_linux_bazel.yml index b91491dacba..c846ef8d425 100644 --- a/.github/workflows/amd64_linux_bazel.yml +++ b/.github/workflows/amd64_linux_bazel.yml @@ -7,14 +7,23 @@ jobs: # Building using the github runner environement directly. bazel: runs-on: ubuntu-latest + strategy: + matrix: + python-version: ['3.7', '3.8', '3.9', '3.10', '3.11'] + fail-fast: false env: CC: gcc-12 CXX: g++-12 steps: - - name: Check out repository code - uses: actions/checkout@v3 - - name: Check java + - uses: actions/checkout@v3 + - name: Check Java run: java -version + - name: Setup Python + uses: actions/setup-python@v3 + with: + python-version: ${{ matrix.python-version }} + - name: Check Python + run: python --version - name: Install Bazel run: | curl -fsSL https://bazel.build/bazel-release.pub.gpg | gpg --dearmor > bazel.gpg diff --git a/.github/workflows/amd64_macos_bazel.yml b/.github/workflows/amd64_macos_bazel.yml index da5d226e6a9..9eec56b0768 100644 --- a/.github/workflows/amd64_macos_bazel.yml +++ b/.github/workflows/amd64_macos_bazel.yml @@ -4,8 +4,13 @@ name: amd64 MacOS Bazel on: [push, pull_request] jobs: + # Building using the github runner environement directly. bazel: runs-on: macos-latest + strategy: + matrix: + python-version: ['3.7', '3.8', '3.9', '3.10', '3.11'] + fail-fast: false steps: - name: Check out repository code uses: actions/checkout@v3 @@ -16,6 +21,12 @@ jobs: java-version: '17' - name: Check mvn run: mvn --version + - name: Setup Python + uses: actions/setup-python@v3 + with: + python-version: ${{ matrix.python-version }} + - name: Check Python + run: python --version - name: Install Bazel run: | brew update diff --git a/.github/workflows/amd64_windows_bazel.yml b/.github/workflows/amd64_windows_bazel.yml index 4f00d3e9fae..220c92a18f3 100644 --- a/.github/workflows/amd64_windows_bazel.yml +++ b/.github/workflows/amd64_windows_bazel.yml @@ -9,6 +9,7 @@ jobs: strategy: matrix: runner: [windows-2022, windows-2019] + python-version: ['3.7', '3.8', '3.9', '3.10', '3.11'] fail-fast: false # Don't cancel all jobs if one fails. runs-on: ${{ matrix.runner }} #runs-on: windows-latest @@ -22,10 +23,16 @@ jobs: run: java -version - name: Check mvn run: mvn --version + - name: Setup Python + uses: actions/setup-python@v3 + with: + python-version: ${{ matrix.python-version }} + - name: Check Python + run: python --version - name: Install Bazel - run: | - choco install bazel - bazel --version + run: choco install bazel + - name: Check Bazel + run: bazel version - name: Build run: > bazel build