File tree Expand file tree Collapse file tree 2 files changed +19
-0
lines changed Expand file tree Collapse file tree 2 files changed +19
-0
lines changed Original file line number Diff line number Diff line change
1
+ # Use a separate pre-commit config that runs only when Rust dependencies
2
+ # are added, removed or modified.
3
+ repos :
4
+ - repo : local
5
+ hooks :
6
+ - id : audit
7
+ name : audit
8
+ language : system
9
+ files : ' Cargo\.lock|Cargo\.toml$'
10
+ # FIXME
11
+ # RUSTSEC-2021-0131 --> https://rustsec.org/advisories/RUSTSEC-2021-0131
12
+ # RUSTSEC-2021-0124 --> https://rustsec.org/advisories/RUSTSEC-2021-0124
13
+ entry : cargo audit --ignore RUSTSEC-2021-0131 --ignore RUSTSEC-2021-0124
14
+ pass_filenames : false
15
+
16
+ default_language_version :
17
+ python : python3
Original file line number Diff line number Diff line change @@ -43,11 +43,13 @@ tasks:
43
43
rustup component add clippy rustfmt &&
44
44
rustup toolchain install nightly &&
45
45
curl -L https://github.com/est31/cargo-udeps/releases/download/v0.1.25/cargo-udeps-v0.1.25-x86_64-unknown-linux-gnu.tar.gz | tar xz -C /usr/local/cargo/bin --strip-components 2 &&
46
+ curl -L https://github.com/rustsec/rustsec/releases/download/cargo-audit%2Fv0.16.0/cargo-audit-x86_64-unknown-linux-musl-v0.16.0.tgz | tar xzv -C /usr/local/cargo/bin --strip-components 1 &&
46
47
git clone --quiet ${repository} &&
47
48
cd rust-code-analysis &&
48
49
git -c advice.detachedHead=false checkout ${head_rev} &&
49
50
pip3 install --quiet pre-commit &&
50
51
pre-commit run -a --show-diff-on-failure &&
52
+ pre-commit run --show-diff-on-failure -c .pre-commit-audit-config.yaml &&
51
53
cargo test --workspace --verbose --all-features &&
52
54
cd enums &&
53
55
cargo build --verbose --all-features"
You can’t perform that action at this time.
0 commit comments