Skip to content

setup ci

setup ci #23

Workflow file for this run

name: CI
on:
push:
branches: [master]
tags:
- '*'
pull_request:
branches: [master]
jobs:
build-macos:
name: Build extension for macos-unversal
runs-on: macos-latest
steps:
- uses: actions/checkout@v2
- name: Set up JDK 11
uses: actions/setup-java@v1
with:
java-version: 11
- name: Set up Rust for macos
uses: actions-rs/toolchain@v1
with:
toolchain: stable
# we need only aarch64 since x86 target is installed by default
target: aarch64-apple-darwin
- name: Build extension
run: make loadable-extension
- name: Test Java
run: cd jdbc && ./gradlew test
- name: Save extension output
if: startsWith(github.ref, 'refs/tags/')
uses: actions/upload-artifact@v2
with:
name: extension-build
path: build/*
build-linux-amd64:
name: Build extension for linux-amd64
runs-on: ubuntu-latest
# We build the extension in the container which is same as the one used for
# duckdb build as of 0.9.1 to avoid any compatibility issues as much as possible
container: quay.io/pypa/manylinux2014_x86_64
steps:
- uses: actions/checkout@v2
- name: Set up JDK 11
uses: actions/setup-java@v1
with:
java-version: 11
- name: Set up Rust for linux
uses: actions-rs/toolchain@v1
with:
toolchain: stable
- name: Setup dependencies
# install llvm-toolset-7 for libclang which is required by bindgen
run: yum install -y llvm-toolset-7
- name: Build extension
run: scl enable llvm-toolset-7 "make loadable-extension"
- name: Test Java
run: cd jdbc && ./gradlew test
- name: Save extension output
if: startsWith(github.ref, 'refs/tags/')
uses: actions/upload-artifact@v2
with:
name: extension-build
path: build/*
test-rust:
name: Execute Rust test for ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
include:
- os: ubuntu-latest
- os: macos-latest
steps:
- uses: actions/checkout@v2
- name: Setup duckdb sources
run: |
make duckdb-sources
- name: Set up Rust
uses: actions-rs/toolchain@v1
with:
toolchain: stable
- name: Test Rust
run: |
cargo test