diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml new file mode 100644 index 0000000..780d547 --- /dev/null +++ b/.github/workflows/ci.yml @@ -0,0 +1,30 @@ +name: CheckCode +on: + push: + +jobs: + fmt: + name: fmt check + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - run: rustup component add rustfmt + - uses: dtolnay/rust-toolchain@stable + with: + components: rustfmt + - run: cargo fmt --all --check + working-directory: ./server + + clippy: + name: clippy check + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4 + - uses: dtolnay/rust-toolchain@stable + with: + components: clippy + - uses: LoliGothick/clippy-check@v0.3.2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + deny: warnings + working-directory: ./server