arnaucube
arnaucube/miden-cryptoPublic Self-hosted repository
miden-crypto/.pre-commit-config.yaml
.pre-commit-config.yamlRaw
 1# See https://pre-commit.com for more information
 2# See https://pre-commit.com/hooks.html for more hooks
 3repos:
 4- repo: https://github.com/pre-commit/pre-commit-hooks
 5  rev: v3.2.0
 6  hooks:
 7    - id: trailing-whitespace
 8    - id: end-of-file-fixer
 9    - id: check-yaml
10    - id: check-json
11    - id: check-toml
12    - id: pretty-format-json
13    - id: check-added-large-files
14    - id: check-case-conflict
15    - id: check-executables-have-shebangs
16    - id: check-merge-conflict
17    - id: detect-private-key
18- repo: https://github.com/hackaugusto/pre-commit-cargo
19  rev: v1.0.0
20  hooks:
21    # Allows cargo fmt to modify the source code prior to the commit
22    - id: cargo
23      name: Cargo fmt
24      args: ["+stable", "fmt", "--all"]
25      stages: [commit]
26    # Requires code to be properly formatted prior to pushing upstream
27    - id: cargo
28      name: Cargo fmt --check
29      args: ["+stable", "fmt", "--all", "--check"]
30      stages: [push, manual]
31    - id: cargo
32      name: Cargo check --all-targets
33      args: ["+stable", "check", "--all-targets"]
34    - id: cargo
35      name: Cargo check --all-targets --no-default-features
36      args: ["+stable", "check", "--all-targets", "--no-default-features"]
37    - id: cargo
38      name: Cargo check --all-targets --all-features
39      args: ["+stable", "check", "--all-targets", "--all-features"]
40    # Unlike fmt, clippy will not be automatically applied
41    - id: cargo
42      name: Cargo clippy
43      args: ["+nightly", "clippy", "--workspace", "--", "--deny", "clippy::all", "--deny", "warnings"]