File tree 1 file changed +34
-1
lines changed
1 file changed +34
-1
lines changed Original file line number Diff line number Diff line change @@ -56,15 +56,48 @@ jobs:
56
56
- name : Checkout repository
57
57
uses : actions/checkout@v4
58
58
59
+ # Set up Rust
60
+ - name : Set up Rust
61
+ uses : actions-rs/toolchain@v1
62
+ with :
63
+ profile : minimal
64
+ toolchain : nightly
65
+ override : true
66
+
59
67
- name : Install cargo-llvm-cov
60
68
uses : taiki-e/install-action@cargo-llvm-cov
61
69
62
70
- name : Install Clippy
63
71
run : rustup component add clippy
64
72
73
+ # Cache Cargo dependencies
74
+ - name : Cache Cargo registry
75
+ uses : actions/cache@v3
76
+ with :
77
+ path : ~/.cargo/registry
78
+ key : ${{ runner.os }}-cargo-registry-${{ hashFiles('**/Cargo.lock') }}
79
+ restore-keys : |
80
+ ${{ runner.os }}-cargo-registry-
81
+
82
+ - name : Cache Cargo index
83
+ uses : actions/cache@v3
84
+ with :
85
+ path : ~/.cargo/git
86
+ key : ${{ runner.os }}-cargo-index-${{ hashFiles('**/Cargo.lock') }}
87
+ restore-keys : |
88
+ ${{ runner.os }}-cargo-index-
89
+
90
+ - name : Cache target directory
91
+ uses : actions/cache@v3
92
+ with :
93
+ path : target
94
+ key : ${{ runner.os }}-cargo-target-${{ hashFiles('**/Cargo.lock') }}
95
+ restore-keys : |
96
+ ${{ runner.os }}-cargo-target-
97
+
65
98
- name : Install cargo-sonar and run Clippy
66
99
run : |
67
- cargo install cargo-sonar
100
+ cargo install cargo-sonar
68
101
cargo clippy --message-format json > my-clippy-report.json
69
102
cargo sonar --issues clippy --clippy-path my-clippy-report.json
70
103
You can’t perform that action at this time.
0 commit comments