From 65cb5d6e762a7cb53f9a95d93ac7237cc8101e0d Mon Sep 17 00:00:00 2001 From: FxQnLr <39925636+FxQnLr@users.noreply.github.com> Date: Sun, 15 Oct 2023 19:05:03 +0200 Subject: Create pull_request.yml --- .github/workflows/pull_request.yml | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 .github/workflows/pull_request.yml diff --git a/.github/workflows/pull_request.yml b/.github/workflows/pull_request.yml new file mode 100644 index 0000000..40a7490 --- /dev/null +++ b/.github/workflows/pull_request.yml @@ -0,0 +1,36 @@ +name: build + +on: + pull_request: + branches: [ "main" ] + workflow_dispatch: + +env: + SCCACHE_GHA_ENABLED: "true" + RUSTC_WRAPPER: "sccache" + SQLX_OFFLINE: "true" + CARGO_TERM_COLOR: always + +jobs: + build: + runs-on: ubuntu-latest + steps: + - name: Run sccache-cache + uses: mozilla-actions/sccache-action@v0.0.3 + + - uses: actions/checkout@v4 + - uses: actions-rs/toolchain@v1 + with: + toolchain: stable + components: rustfmt, clippy + override: true + + - name: Run cargo check + uses: actions-rs/cargo@v1 + with: + command: check + + - name: Run Clippy + uses: actions-rs/cargo@v1 + with: + command: clippy -- cgit v1.2.3