Switched from custom pre-commit script to using the pre-commit tool
Some checks failed
Build and deploy automation_rs / Build automation_rs (push) Failing after 44s
Build and deploy automation_rs / Build Docker image (push) Has been skipped
Build and deploy automation_rs / Deploy Docker container (push) Has been skipped

This commit is contained in:
2024-05-07 23:40:23 +02:00
parent 794b8eef19
commit 65de771531
4 changed files with 56 additions and 25 deletions

View File

@@ -15,17 +15,30 @@ jobs:
- name: Checkout
uses: actions/checkout@v4
# - uses: actions/setup-go@v3
# with:
# go-version: ">=1.20.1"
- uses: https://gitea.com/actions/go-hashfiles@v0.0.1
id: hash-go
with:
patterns: |
.pre-commit-config.yaml
- uses: actions/cache@v3
with:
path: ~/.cache/pre-commit
key: pre-commit-3|${{ env.pythonLocation }}|${{ steps.hash-go.outputs.hash }}
- run: python -m pip install pre-commit
shell: bash
- run: pre-commit run --show-diff-on-failure --color=always
shell: bash
- name: Setup Rust
uses: actions-rust-lang/setup-rust-toolchain@v1
with:
rustflags: ""
- name: Formatting
uses: actions-rust-lang/rustfmt@v1
- name: Clippy
run: cargo clippy --all-targets --all -- -D warnings
- name: Build
run: cargo build --release