Fix critical security issues #3, #5, #17, #20 #132
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: CI | |
| on: | |
| push: | |
| branches: [main] | |
| pull_request: | |
| branches: [main] | |
| jobs: | |
| test: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: dtolnay/rust-toolchain@stable | |
| with: | |
| components: rustfmt, clippy, llvm-tools-preview | |
| - uses: Swatinem/rust-cache@v2 | |
| - name: Install cargo-llvm-cov | |
| uses: taiki-e/install-action@cargo-llvm-cov | |
| - run: cargo fmt --check | |
| - run: cargo clippy --workspace --all-targets -- -D warnings | |
| - run: cargo test --workspace | |
| - name: Check documentation (catches broken intra-doc links) | |
| env: | |
| RUSTDOCFLAGS: "-D warnings" | |
| run: cargo doc --workspace --no-deps --document-private-items | |
| - name: Generate and print code coverage | |
| run: cargo llvm-cov --workspace | |
| - name: Generate code coverage HTML report | |
| run: cargo llvm-cov report --html --output-dir coverage | |
| - name: Upload coverage report artifact | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: coverage-report | |
| path: coverage/ | |
| wasm-build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: dtolnay/rust-toolchain@stable | |
| with: | |
| targets: wasm32v1-none | |
| - uses: Swatinem/rust-cache@v2 | |
| - run: cargo build --target wasm32v1-none --release | |
| - name: Upload built .wasm artifacts | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: wasm-build-${{ github.sha }} | |
| path: target/wasm32v1-none/release/*.wasm | |
| if-no-files-found: error |