name: Ubuntu on: [push] jobs: build: runs-on: ubuntu-latest strategy: matrix: ruby: ['2.5.8', '2.6.8', '2.7.4', '3.0.2', 'head'] duckdb: ['0.2.8', '0.2.7'] steps: - uses: actions/checkout@v2 - name: Set up Ruby uses: ruby/setup-ruby@v1 with: ruby-version: ${{ matrix.ruby }} - name: duckdb 0.2.8 cache id: duckdb-cache-v0_2_8 uses: actions/cache@v1.1.0 with: path: duckdb-v0.2.8 key: ${{ runner.os }}-duckdb-v0_2_8_001 restore-keys: | ${{ runner.os }}-duckdb-v0_2_8 - name: duckdb 0.2.7 cache id: duckdb-cache-v0_2_7 uses: actions/cache@v1.1.0 with: path: duckdb-v0.2.7 key: ${{ runner.os }}-duckdb-v0_2_7_001 restore-keys: | ${{ runner.os }}-duckdb-v0_2_7 - name: Build duckdb 0.2.8 if: steps.duckdb-cache-v0_2_8.outputs.cache-hit != 'true' run: | git clone -b v0.2.8 https://github.com/cwida/duckdb.git duckdb-tmp-v0.2.8 cd duckdb-tmp-v0.2.8 && make && cd .. rm -rf duckdb-v0.2.8 mkdir -p duckdb-v0.2.8/build/release/src duckdb-v0.2.8/src cp -rip duckdb-tmp-v0.2.8/build/release/src/*.so duckdb-v0.2.8/build/release/src cp -rip duckdb-tmp-v0.2.8/src/include duckdb-v0.2.8/src/ - name: Build duckdb 0.2.7 if: steps.duckdb-cache-v0_2_7.outputs.cache-hit != 'true' run: | git clone -b v0.2.7 https://github.com/cwida/duckdb.git duckdb-tmp-v0.2.7 cd duckdb-tmp-v0.2.7 && make && cd .. rm -rf duckdb-v0.2.7 mkdir -p duckdb-v0.2.7/build/release/src duckdb-v0.2.7/src cp -rip duckdb-tmp-v0.2.7/build/release/src/*.so duckdb-v0.2.7/build/release/src cp -rip duckdb-tmp-v0.2.7/src/include duckdb-v0.2.7/src/ - name: Build and test with Rake with Ruby ${{ matrix.ruby }} env: DUCKDB_VERSION: ${{ matrix.duckdb }} run: | gem install bundler bundle install --jobs 4 --retry 3 bundle exec rake -- --with-duckdb-include=${GITHUB_WORKSPACE}/duckdb-v${DUCKDB_VERSION}/src/include --with-duckdb-lib=${GITHUB_WORKSPACE}/duckdb-v${DUCKDB_VERSION}/build/release/src/