Split CI into separate groups of steps

This commit is contained in:
Andrew Kane
2022-12-08 00:26:48 -08:00
parent 9c9489e888
commit 4fbe55f97e

View File

@@ -1,16 +1,12 @@
name: build name: build
on: [push, pull_request] on: [push, pull_request]
jobs: jobs:
build: ubuntu:
runs-on: ${{ matrix.os }} runs-on: ubuntu-latest
strategy: strategy:
fail-fast: false fail-fast: false
matrix: matrix:
os: [ubuntu-latest]
postgres: [15, 14, 13, 12, 11, 10] postgres: [15, 14, 13, 12, 11, 10]
include:
- os: macos-latest
postgres: 14
steps: steps:
- uses: actions/checkout@v3 - uses: actions/checkout@v3
- uses: ankane/setup-postgres@v1 - uses: ankane/setup-postgres@v1
@@ -18,22 +14,29 @@ jobs:
postgres-version: ${{ matrix.postgres }} postgres-version: ${{ matrix.postgres }}
dev-files: true dev-files: true
- run: make - run: make
- if: ${{ startsWith(matrix.os, 'ubuntu') }} - run: |
run: |
export PG_CONFIG=`which pg_config` export PG_CONFIG=`which pg_config`
sudo --preserve-env=PG_CONFIG make install sudo --preserve-env=PG_CONFIG make install
- if: ${{ startsWith(matrix.os, 'macos') }}
run: make install
- run: make installcheck - run: make installcheck
- if: ${{ failure() }} - if: ${{ failure() }}
run: cat regression.diffs run: cat regression.diffs
- if: ${{ startsWith(matrix.os, 'ubuntu') }} - run: |
run: |
sudo apt-get update sudo apt-get update
sudo apt-get install libipc-run-perl sudo apt-get install libipc-run-perl
make prove_installcheck make prove_installcheck
- if: ${{ startsWith(matrix.os, 'macos') }} mac:
run: | runs-on: macos-latest
steps:
- uses: actions/checkout@v3
- uses: ankane/setup-postgres@v1
with:
postgres-version: 14
- run: make
- run: make install
- run: make installcheck
- if: ${{ failure() }}
run: cat regression.diffs
- run: |
brew install cpanm brew install cpanm
cpanm IPC::Run cpanm IPC::Run
wget -q https://github.com/postgres/postgres/archive/refs/tags/REL_14_5.tar.gz wget -q https://github.com/postgres/postgres/archive/refs/tags/REL_14_5.tar.gz