File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Load Diff This file was deleted.
Original file line number Diff line number Diff line change 11#! /bin/sh
2- set -e pipefail
2+ set -e
3+
4+ # Dependency sorting
5+ if ! cargo sort --workspace --check; then
6+ echo " ❌ Dependencies should be sorted (run 'cargo sort --workspace')"
7+ exit 1
8+ fi
39
410# Dependency audit
5- cargo deny check || {
11+ if ! cargo deny check; then
612 echo " ❌ Critical: Vulnerable dependencies detected (run 'cargo deny check')"
7- exit 1
8- }
13+ exit 2
14+ fi
915
1016# Formatting check
11- cargo fmt --all -- --check || {
17+ if ! cargo fmt --all -- --check; then
1218 echo " ❌ Formatting issues (run 'cargo fmt --all')"
13- exit 2
14- }
19+ exit 3
20+ fi
1521
1622# Typo check
17- typos || {
23+ if ! typos ; then
1824 echo " ❌ Spelling mistakes found (run 'typos --write-changes')"
19- exit 3
20- }
25+ exit 4
26+ fi
2127
2228# Linting
23- cargo clippy --all-targets --all-features -- -D warnings || {
29+ if ! cargo clippy --all-targets --all-features -- -D warnings; then
2430 echo " ❌ Clippy violations (check warnings above)"
25- exit 4
26- }
31+ exit 5
32+ fi
2733
2834# Tests
29- cargo test --workspace --verbose || {
35+ if ! cargo test --workspace --verbose; then
3036 echo " ❌ Test failures detected"
31- exit 5
32- }
37+ exit 6
38+ fi
3339
3440echo " ✅ All checks passed!"
Original file line number Diff line number Diff line change 1+
2+ # TODO(template) update for the crate name
3+ [workspace ]
4+ members = [" examples" , " mycrate" ]
5+ resolver = " 2"
6+ default-members = [" mycrate" ]
17[workspace .package ]
28version = " 0.1.0"
39edition = " 2021"
410# TODO(template) update for your repository
511repository = " https://github.com/NethermindEth/rust-template"
612license = " Apache-2.0" # TODO(template) update license if needed
713
8- # TODO(template) update for the crate name
9- [workspace ]
10- members = [
11- " examples" ,
12- " mycrate" ,
13- ]
14- resolver = " 2"
15- default-members = [" mycrate" ]
16-
1714[workspace .dependencies ]
1815
1916[workspace .lints .rust ]
@@ -33,4 +30,4 @@ cast_precision_loss = "deny"
3330cast_sign_loss = " deny"
3431needless_return = " deny"
3532panicking_overflow_checks = " deny"
36- unwrap_used = " deny"
33+ unwrap_used = " deny"
You can’t perform that action at this time.
0 commit comments