From 8622406f18f7b86dc694b7f9ed5be53b9c2dfcc3 Mon Sep 17 00:00:00 2001 From: Tanguy Date: Tue, 10 Jan 2023 15:05:25 +0100 Subject: [PATCH] Add CI --- .github/workflows/ci.yml | 67 ++++++++++++++++++++++++++++++++++++++++ 1 file changed, 67 insertions(+) create mode 100644 .github/workflows/ci.yml diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..4cb9b66 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,67 @@ +name: CI +on: + push: + +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} + cancel-in-progress: true + +jobs: + build: + timeout-minutes: 30 + strategy: + fail-fast: false + matrix: + target: + - os: linux + cpu: amd64 + - os: linux + cpu: i386 + - os: macos + cpu: amd64 + - os: windows + cpu: amd64 + nim: [1.2.18, 1.6.10, devel] + include: + - target: + os: linux + builder: ubuntu-20.04 + shell: bash + - target: + os: macos + builder: macos-12 + shell: bash + - target: + os: windows + builder: windows-2019 + shell: msys2 {0} + + defaults: + run: + shell: ${{ matrix.shell }} + + name: '${{ matrix.target.os }}-${{ matrix.target.cpu }} (Nim ${{ matrix.nim }})' + runs-on: ${{ matrix.builder }} + steps: + - name: Checkout + uses: actions/checkout@v2 + with: + submodules: true + + - uses: iffy/install-nim@v3 + with: + version: ${{ matrix.nim }} + + + - name: Install deps + run: | + nimble install -dy + + - name: Run tests + run: | + nim --version + nimble --version + #TODO + #nimble test + nim c examples/sctp_ping.nim + nim c examples/sctp_pong.nim