35 lines
732 B
YAML
35 lines
732 B
YAML
|
#
|
||
|
# Configuration for GitHub-based CI, based on the stock GitHub Rust config.
|
||
|
#
|
||
|
name: Build
|
||
|
|
||
|
on:
|
||
|
push:
|
||
|
branches: [ main ]
|
||
|
pull_request:
|
||
|
branches: [ main ]
|
||
|
|
||
|
jobs:
|
||
|
check-style:
|
||
|
runs-on: ubuntu-18.04
|
||
|
steps:
|
||
|
- uses: actions/checkout@v2
|
||
|
- name: Report cargo version
|
||
|
run: cargo --version
|
||
|
- name: Report rustfmt version
|
||
|
run: cargo fmt -- --version
|
||
|
- name: Check style
|
||
|
run: cargo fmt -- --check
|
||
|
|
||
|
build-and-test:
|
||
|
runs-on: ${{ matrix.os }}
|
||
|
strategy:
|
||
|
matrix:
|
||
|
os: [ ubuntu-18.04, windows-2019, macos-10.15 ]
|
||
|
steps:
|
||
|
- uses: actions/checkout@v2
|
||
|
- name: Build
|
||
|
run: cargo build --tests --verbose
|
||
|
- name: Run tests
|
||
|
run: cargo test --verbose
|