From fa69b2ad895dc14f477a5b6b33d59fcedcef8b2e Mon Sep 17 00:00:00 2001 From: Michael Kirk Date: Tue, 16 Feb 2021 11:16:38 -0800 Subject: [PATCH 1/2] build matrix --- .github/workflows/test.yml | 15 ++++++++++++--- 1 file changed, 12 insertions(+), 3 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 4c4969a55..6c8154f7b 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -8,8 +8,11 @@ jobs: defaults: run: working-directory: geo-types + strategy: + matrix: + container_image: ["georust/geo-ci:rust-1.49", "georust/geo-ci:rust-1.50"] container: - image: georust/geo-ci + image: ${{ matrix.container_image }} steps: - name: Checkout repository uses: actions/checkout@v2 @@ -24,8 +27,11 @@ jobs: defaults: run: working-directory: geo + strategy: + matrix: + container_image: ["georust/geo-ci:rust-1.49", "georust/geo-ci:rust-1.50"] container: - image: georust/geo-ci + image: ${{ matrix.container_image }} steps: - name: Checkout repository uses: actions/checkout@v2 @@ -40,8 +46,11 @@ jobs: defaults: run: working-directory: geo-postgis + strategy: + matrix: + container_image: ["georust/geo-ci:rust-1.49", "georust/geo-ci:rust-1.50"] container: - image: georust/geo-ci + image: ${{ matrix.container_image }} steps: - name: Checkout repository uses: actions/checkout@v2 From c169918826af4113208bba10eed676ce4f13011e Mon Sep 17 00:00:00 2001 From: Michael Kirk Date: Mon, 22 Feb 2021 15:45:00 -0800 Subject: [PATCH 2/2] easier CI organization for bors --- .github/workflows/test.yml | 23 +++++++++++++++++++++++ bors.toml | 6 +----- 2 files changed, 24 insertions(+), 5 deletions(-) diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 6c8154f7b..f877c7dbd 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -1,6 +1,29 @@ on: push name: Run tests jobs: + # The `ci-result` job doesn't actually test anything - it just aggregates the + # overall build status for bors, otherwise our bors.toml would need an entry + # for each individual job produced by the job-matrix. + # + # Ref: https://github.com/rust-lang/crater/blob/9ab6f9697c901c4a44025cf0a39b73ad5b37d198/.github/workflows/bors.yml#L125-L149 + # + # ALL THE SUBSEQUENT JOBS NEED THEIR `name` ADDED TO THE `needs` SECTION OF THIS JOB! + ci-result: + name: ci result + runs-on: ubuntu-latest + needs: + - geo_types + - geo + - geo_postgis + - coverage + - bench + steps: + - name: Mark the job as a success + if: success() + run: exit 0 + - name: Mark the job as a failure + if: "!success()" + run: exit 1 geo_types: name: geo-types runs-on: ubuntu-latest diff --git a/bors.toml b/bors.toml index 598abf469..bfa4661a1 100644 --- a/bors.toml +++ b/bors.toml @@ -1,7 +1,3 @@ status = [ - "geo-types", - "geo", - "geo-postgis", - "coverage", - "bench" + "ci result", ]