name: CI

on:
  pull_request:
  push:
    branches-ignore:
    - coverity_scan
    paths-ignore:
    - '.circleci/**'
    - '.github/actions/spelling/**'
    - 'docs/**'
    - 'packages**'
    - .cirrus.yml
    - .clang-format
    - .gitignore
    - .travis.yml
    - AUTHORS
    - COPYRIGHT
    - ChangeLog.md
    - LICENSE
    - README.md
    - appveyor.yml

jobs:
  build:
    runs-on: ${{ matrix.os }}
    strategy:
      matrix:
#, windows-latest
        os: [ubuntu-latest, macos-latest, ubuntu-18.04]
    steps:
    - uses: actions/checkout@v2
    - name: fetch tags
      run: git fetch --unshallow --tags --prune --force
    - name: make check
      run: make MDBX_BUILD_OPTIONS="-DNDEBUG=1 -DMDBX_FORCE_ASSERTIONS=1" --keep-going all && MALLOC_CHECK_=7 MALLOC_PERTURB_=42 make MDBX_BUILD_OPTIONS="-DNDEBUG=1 -DMDBX_FORCE_ASSERTIONS=1" --keep-going check
      shell: bash