Skip to content

Commit

Permalink
ci: add initial CI workflow (#40)
Browse files Browse the repository at this point in the history
Adds GitHub CI tasks to build the C library and check the formatting of the Rust library.
  • Loading branch information
abrown committed Feb 9, 2022
1 parent 3a19f62 commit 13fc58e
Showing 1 changed file with 36 additions and 0 deletions.
36 changes: 36 additions & 0 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
name: Rust

on:
push:
branches: [ master ]
pull_request:
branches: [ master ]

env:
CARGO_TERM_COLOR: always

jobs:
c_build:
name: Check upstream C library
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
steps:
- uses: actions/checkout@v2
with:
submodules: recursive
- name: Build C library
run: python buildall.py

rust_format:
name: Check Rust formatting
runs-on: ubuntu-latest
defaults:
run:
working-directory: ittapi-rs
steps:
- uses: actions/checkout@v2
- run: rustup component add rustfmt
- run: cargo fmt --all -- --check

0 comments on commit 13fc58e

Please sign in to comment.