|
- name: CI
-
- on:
- push:
- pull_request:
- workflow_dispatch:
-
- jobs:
- test:
- name: "Test"
- strategy:
- matrix:
- platform: [ubuntu-latest, macos-latest, windows-latest]
- fail-fast: false
- runs-on: ${{ matrix.platform }}
- timeout-minutes: 30
- steps:
- - uses: actions/checkout@v2
- - name: Install Cap'n Proto and libacl-dev (Linux)
- if: runner.os == 'Linux'
- run: |
- export DEBIAN_FRONTEND=noninteractive
- sudo apt-get install -y capnproto libcapnp-dev libacl1-dev
- - name: Install Cap'n Proto (macOS)
- if: runner.os == 'macOS'
- run: brew install capnp
- env:
- HOMEBREW_NO_AUTO_UPDATE: 1
- HOMEBREW_NO_BOTTLE_SOURCE_FALLBACK: 1
- HOMEBREW_NO_INSTALL_CLEANUP: 1
- - name: Install Cap'n Proto (Windows)
- if: runner.os == 'Windows'
- shell: pwsh
- run: |
- choco install capnproto
- echo "$Env:Programfiles\capnproto" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
-
- - name: "Check"
- uses: actions-rs/cargo@v1
- with:
- command: check
- args: --all
- - name: "Build"
- uses: actions-rs/cargo@v1
- with:
- command: build
- args: --all
- - name: "Test"
- uses: actions-rs/cargo@v1
- with:
- command: test
- args: --all
-
- examples:
- name: "Examples"
- strategy:
- matrix:
- platform: [ubuntu-latest, macos-latest, windows-latest]
- fail-fast: false
- runs-on: ${{ matrix.platform }}
- steps:
- - uses: actions/checkout@v2
-
- - name: Install Cap'n Proto and libacl-dev (Linux)
- if: runner.os == 'Linux'
- run: |
- export DEBIAN_FRONTEND=noninteractive
- sudo apt-get install -y capnproto libcapnp-dev libacl1-dev
- - name: Install Cap'n Proto (macOS)
- if: runner.os == 'macOS'
- run: brew install capnp
- env:
- HOMEBREW_NO_AUTO_UPDATE: 1
- HOMEBREW_NO_BOTTLE_SOURCE_FALLBACK: 1
- HOMEBREW_NO_INSTALL_CLEANUP: 1
- - name: Install Cap'n Proto (Windows)
- if: runner.os == 'Windows'
- shell: pwsh
- run: |
- choco install capnproto
- echo "$Env:Programfiles\capnproto" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
-
- - name: "Build examples"
- uses: actions-rs/cargo@v1
- timeout-minutes: 30
- with:
- command: build
- args: --examples
-
- - name: "Rust Dataflow example"
- uses: actions-rs/cargo@v1
- timeout-minutes: 30
- with:
- command: run
- args: --example rust-dataflow
- - name: "C Dataflow example"
- uses: actions-rs/cargo@v1
- timeout-minutes: 15
- with:
- command: run
- args: --example c-dataflow
- - name: "C++ Dataflow example"
- uses: actions-rs/cargo@v1
- timeout-minutes: 15
- with:
- command: run
- args: --example cxx-dataflow
-
- - name: "Start RouDi (iceoryx)"
- if: runner.os != 'Windows'
- run: find target -type f -wholename "*/iceoryx-install/bin/iox-roudi" -exec {} \; &
-
- - name: "Rust iceoryx example"
- if: runner.os != 'Windows'
- uses: actions-rs/cargo@v1
- timeout-minutes: 30
- with:
- command: run
- args: --example iceoryx
-
- clippy:
- name: "Clippy"
- runs-on: ubuntu-latest
- steps:
- - uses: actions/checkout@v2
- - name: Install Cap'n Proto and libacl-dev
- run: |
- export DEBIAN_FRONTEND=noninteractive
- sudo apt-get install -y capnproto libcapnp-dev libacl1-dev
- - name: "Clippy"
- uses: actions-rs/cargo@v1
- with:
- command: clippy
- args: --all
- - name: "Clippy (tracing feature)"
- uses: actions-rs/cargo@v1
- with:
- command: clippy
- args: --all --features tracing
- - name: "Clippy (metrics feature)"
- uses: actions-rs/cargo@v1
- with:
- command: clippy
- args: --all --features metrics
-
- rustfmt:
- name: "Formatting"
- runs-on: ubuntu-latest
- steps:
- - uses: actions/checkout@v2
- - name: "rustfmt"
- run: cargo fmt --all -- --check
-
- check-license:
- name: "License Checks"
- runs-on: ubuntu-latest
- steps:
- - uses: actions/checkout@v2
- - run: cargo install cargo-lichking
- - name: "Check dependency licenses"
- run: cargo lichking check
|