56 lines
1.1 KiB
YAML
56 lines
1.1 KiB
YAML
![]() |
name: CI
|
||
|
|
||
|
on:
|
||
|
push:
|
||
|
pull_request:
|
||
|
|
||
|
env:
|
||
|
CARGO_TERM_COLOR: always
|
||
|
|
||
|
jobs:
|
||
|
build-javascript:
|
||
|
name: Build JavaScript
|
||
|
runs-on: ubuntu-latest
|
||
|
steps:
|
||
|
- uses: actions/checkout@v3
|
||
|
- uses: actions/setup-node@v3
|
||
|
with:
|
||
|
node-version: 16
|
||
|
- run: npm ci
|
||
|
- run: node_modules/.bin/vite build
|
||
|
|
||
|
test:
|
||
|
name: Test
|
||
|
runs-on: ubuntu-latest
|
||
|
strategy:
|
||
|
matrix:
|
||
|
toolchain:
|
||
|
- 1.56
|
||
|
- stable
|
||
|
- beta
|
||
|
- nightly
|
||
|
steps:
|
||
|
- uses: actions/checkout@v3
|
||
|
- run: rustup update ${{ matrix.toolchain }}
|
||
|
- run: rustup default ${{ matrix.toolchain }}
|
||
|
- run: cargo build --verbose
|
||
|
- run: cargo test --verbose
|
||
|
|
||
|
prettier:
|
||
|
name: Prettier
|
||
|
runs-on: ubuntu-latest
|
||
|
steps:
|
||
|
- uses: actions/checkout@v3
|
||
|
- uses: actions/setup-node@v3
|
||
|
with:
|
||
|
node-version: 16
|
||
|
- run: npm ci
|
||
|
- run: npx prettier --check .
|
||
|
|
||
|
rustfmt:
|
||
|
name: Rustfmt
|
||
|
runs-on: ubuntu-latest
|
||
|
steps:
|
||
|
- uses: actions/checkout@v3
|
||
|
- run: cargo fmt --all --check
|