From 707d2f2fe8601c1f425be1233a72bac872c0b4b9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=86var=20Arnfj=C3=B6r=C3=B0=20Bjarmason?= Date: Tue, 23 Nov 2021 17:29:11 +0100 Subject: CI: use "$runs_on_pool", not "$jobname" to select packages & config MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Change the setup hooks for the CI to use "$runs_on_pool" for the "$regular" job. Now we won't need as much boilerplate when adding new jobs to the "regular" matrix, see 956d2e4639b (tests: add a test mode for SANITIZE=leak, run it in CI, 2021-09-23) for the last such commit. I.e. now instead of needing to enumerate each jobname when we select packages we can install things depending on the pool we're running in. That we didn't do this dates back to the now gone dependency on Travis CI, but even if we add a new CI target in the future this'll be easier to port over, since we can probably treat "ubuntu-latest" as a stand-in for some recent Linux that can run "apt" commands. Signed-off-by: Ævar Arnfjörð Bjarmason Signed-off-by: Junio C Hamano --- .github/workflows/main.yml | 4 ++++ 1 file changed, 4 insertions(+) (limited to '.github/workflows') diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 91b565f75b..d402402a18 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -227,12 +227,14 @@ jobs: pool: ubuntu-latest - jobname: linux-gcc cc: gcc + cc_package: gcc-8 pool: ubuntu-latest - jobname: osx-clang cc: clang pool: macos-latest - jobname: osx-gcc cc: gcc + cc_package: gcc-9 pool: macos-latest - jobname: linux-gcc-default cc: gcc @@ -242,7 +244,9 @@ jobs: pool: ubuntu-latest env: CC: ${{matrix.vector.cc}} + CC_PACKAGE: ${{matrix.vector.cc_package}} jobname: ${{matrix.vector.jobname}} + runs_on_pool: ${{matrix.vector.pool}} runs-on: ${{matrix.vector.pool}} steps: - uses: actions/checkout@v2 -- cgit v1.2.3