diff --git a/.github/workflows/cargo-build.yml b/.github/workflows/cargo-build.yml new file mode 100644 index 0000000..6a81255 --- /dev/null +++ b/.github/workflows/cargo-build.yml @@ -0,0 +1,32 @@ +name: main + +on: + push: + branches: [ main, dev ] + pull_request: + +env: + CARGO_TERM_COLOR: always + +jobs: + build_and_test: + name: OVOS Message bus + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + + - uses: Swatinem/rust-cache@v2 + + - name: setup toolchain + uses: hecrj/setup-rust-action@v2 + with: + rust-version: stable + + - name: cargo test + run: cargo test --all-features + + - name: rustfmt + run: cargo fmt --all -- --check + + - name: clippy + run: cargo clippy --all --all-features --tests -- -D warnings