Adding documentation and exposing more configs to help used customize… #87
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: rust | |
| on: | |
| push: | |
| branches: ["main"] | |
| paths-ignore: | |
| - 'README.md' | |
| pull_request: | |
| branches: ["main"] | |
| paths-ignore: | |
| - 'README.md' | |
| env: | |
| CARGO_TERM_COLOR: always | |
| concurrency: | |
| group: ${{ github.workflow }}-${{ github.ref }} | |
| cancel-in-progress: true | |
| jobs: | |
| build-test-matrix: | |
| name: Build and test native on ${{ matrix.os }} | |
| runs-on: ${{ matrix.os }} | |
| strategy: | |
| matrix: | |
| os: [ubuntu-latest, macos-latest, windows-latest] | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: dtolnay/rust-toolchain@stable | |
| - name: Build | |
| run: cargo build --all-targets --all-features --locked | |
| - name: Test | |
| run: cargo test --all-targets --all-features --locked | |
| build-wasm: | |
| name: Build wasm | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Install targets | |
| run: rustup target add wasm32-unknown-unknown | |
| - name: Build | |
| run: cargo build --target wasm32-unknown-unknown --verbose | |
| build-demos: | |
| name: Build demos | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Build | |
| run: | | |
| set -euxo pipefail | |
| for d in demos/*/ ; do | |
| echo "Building demo $d" | |
| (cd "$d" && CARGO_TARGET_DIR=../target cargo build --verbose) | |
| done | |
| clippy: | |
| name: Check clippy | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: dtolnay/rust-toolchain@stable | |
| with: | |
| components: clippy | |
| - name: Check | |
| run: cargo clippy --all-targets --all-features -- -D warnings -A clippy::new-without-default | |
| fmt: | |
| name: Check rustfmt | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: dtolnay/rust-toolchain@stable | |
| with: | |
| components: rustfmt | |
| - name: Check | |
| run: cargo fmt --check | |
| miri: | |
| name: Test miri | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: dtolnay/rust-toolchain@nightly | |
| with: | |
| components: miri | |
| - name: Prepare | |
| run: cargo miri setup | |
| - name: Test | |
| run: cargo miri test |