4
4
5
5
j := quote (just_executable ())
6
6
7
+ # List available recipes
7
8
default :
8
9
{{ j }} --list
9
10
10
11
alias t := test
11
12
alias c := check
12
13
alias nt := nextest
13
14
14
- # run all tests, clippy, including journey tests, try building docs
15
+ # Run all tests, clippy, including journey tests, try building docs
15
16
test : clippy check doc unit-tests journey-tests-pure journey-tests-small journey-tests-async journey-tests check-mode
16
17
17
- # run all tests, without clippy, and try building docs
18
+ # Run all tests, without clippy, and try building docs
18
19
ci-test : check doc unit-tests check-mode
19
20
20
- # run all journey tests - should be run in a fresh clone or after `cargo clean`
21
+ # Run all journey tests - should be run in a fresh clone or after `cargo clean`
21
22
ci-journey-tests : journey-tests-pure journey-tests-small journey-tests-async journey-tests
22
23
24
+ # Clean the `target` directory
23
25
clear-target :
24
26
cargo clean
25
27
26
- # Run cargo clippy on all crates
28
+ # Run ` cargo clippy` on all crates
27
29
clippy * clippy -args :
28
30
cargo clippy --workspace --all-targets -- {{ clippy-args }}
29
31
cargo clippy --workspace --no-default-features --features small -- {{ clippy-args }}
30
32
cargo clippy --workspace --no-default-features --features max-pure -- {{ clippy-args }}
31
33
cargo clippy --workspace --no-default-features --features lean-async --tests -- {{ clippy-args }}
32
34
33
- # Run cargo clippy on all crates, fixing what can be fixed, and format all code
35
+ # Run ` cargo clippy` on all crates, fixing what can be fixed, and format all code
34
36
clippy-fix :
35
37
cargo clippy --fix --workspace --all-targets
36
38
cargo clippy --fix --allow-dirty --workspace --no-default-features --features small
@@ -145,12 +147,12 @@ check:
145
147
cargo check -p gix-odb --features serde
146
148
cargo check --no-default-features --features max-control
147
149
148
- # Run cargo doc on all crates
150
+ # Run ` cargo doc` on all crates
149
151
doc $ RUSTDOCFLAGS = ' -D warnings':
150
152
cargo doc --workspace --no-deps --features need-more-recent-msrv
151
153
cargo doc --features=max,lean,small --workspace --no-deps --features need-more-recent-msrv
152
154
153
- # run all unit tests
155
+ # Run all unit tests
154
156
unit-tests :
155
157
cargo nextest run
156
158
cargo test --doc
@@ -193,71 +195,72 @@ unit-tests:
193
195
unit-tests-flaky :
194
196
cargo test -p gix --features async-network-client-async-std
195
197
196
- # depend on this to pre-generate metadata, and/or use it inside a recipe as `"$({{ j }} dbg)"`
198
+ # Depend on this to pre-generate metadata, and/or use it inside a recipe as `"$({{ j }} dbg)"`
197
199
[private ]
198
200
dbg :
199
201
set -eu; \
200
202
target_dir=" $(cargo metadata --format-version 1 | jq -r .target_directory)" ; \
201
203
test -n " $target_dir" ; \
202
204
echo " $target_dir/debug"
203
205
204
- # run journey tests (max)
206
+ # Run journey tests (` max` )
205
207
journey-tests : dbg
206
208
cargo build --features http-client-curl-rustls
207
209
cargo build -p gix-testtools --bin jtt
208
210
dbg=" $({{ j }} dbg)" && tests/ journey.sh " $dbg/ein" " $dbg/gix" " $dbg/jtt" max
209
211
210
- # run journey tests (max-pure)
212
+ # Run journey tests (` max-pure` )
211
213
journey-tests-pure : dbg
212
214
cargo build --no-default-features --features max-pure
213
215
cargo build -p gix-testtools --bin jtt
214
216
dbg=" $({{ j }} dbg)" && tests/ journey.sh " $dbg/ein" " $dbg/gix" " $dbg/jtt" max-pure
215
217
216
- # run journey tests (small)
218
+ # Run journey tests (` small` )
217
219
journey-tests-small : dbg
218
220
cargo build --no-default-features --features small
219
221
cargo build -p gix-testtools
220
222
dbg=" $({{ j }} dbg)" && tests/ journey.sh " $dbg/ein" " $dbg/gix" " $dbg/jtt" small
221
223
222
- # run journey tests (lean-async)
224
+ # Run journey tests (` lean-async` )
223
225
journey-tests-async : dbg
224
226
cargo build --no-default-features --features lean-async
225
227
cargo build -p gix-testtools
226
228
dbg=" $({{ j }} dbg)" && tests/ journey.sh " $dbg/ein" " $dbg/gix" " $dbg/jtt" async
227
229
228
- # Run cargo- diet on all crates to see that they are still in bound
230
+ # Run ` cargo diet` on all crates to see that they are still in bounds
229
231
check-size :
230
232
etc/ check-package-size.sh
231
233
232
- # Check the minimal support rust version for currently installed Rust version
234
+ # Check the minimal support Rust version, with the currently installed Rust version
233
235
ci-check-msrv :
234
236
rustc --version
235
237
cargo check -p gix
236
238
cargo check -p gix --no-default-features --features async-network-client,max-performance
237
239
238
- # Enter a nix-shell able to build on macos
240
+ # Enter a nix-shell able to build on macOS
239
241
nix-shell-macos :
240
242
nix-shell -p pkg-config openssl libiconv darwin.apple_sdk.frameworks.Security darwin.apple_sdk.frameworks.SystemConfiguration
241
243
242
- # run various auditing tools to assure we are legal and safe
244
+ # Run various auditing tools to help us stay legal and safe
243
245
audit :
244
246
cargo deny check advisories bans licenses sources
245
247
246
- # run tests with `cargo nextest` (all unit-tests, no doc-tests, faster)
248
+ # Run tests with `cargo nextest` (all unit-tests, no doc-tests, faster)
247
249
nextest * FLAGS = ' --workspace':
248
250
cargo nextest run {{ FLAGS }}
249
251
252
+ # Run tests with `cargo nextest`, skipping none except as filtered, omitting status reports
250
253
summarize EXPRESSION = ' all()':
251
254
cargo nextest run --workspace --run-ignored all --no-fail-fast \
252
255
- -status-level none --final-status-level none -E {{ quote (EXPRESSION) }}
253
256
254
- # run nightly rustfmt for its extra features, but check that it won't upset stable rustfmt
257
+ # Run nightly ` rustfmt` for its extra features, but check that it won't upset stable ` rustfmt`
255
258
fmt :
256
259
cargo + nightly fmt --all -- --config-path rustfmt-nightly.toml
257
260
cargo + stable fmt --all -- --check
258
261
{{ j }} --fmt --unstable
259
262
260
- # Cancel this after the first few seconds, as yanked crates will appear in warnings.
263
+ # Cancel this after the first few seconds, as yanked crates will appear in warnings
261
264
find-yanked :
262
265
cargo install --debug --locked --no-default-features --features max-pure --path .
263
266
@@ -266,6 +269,6 @@ check-mode:
266
269
cargo build -p internal-tools
267
270
cargo run -p internal-tools -- check-mode
268
271
269
- # Delete gix-packetline-blocking/src and regenerate from gix-packetline/src
272
+ # Delete ` gix-packetline-blocking/src` and regenerate from ` gix-packetline/src`
270
273
copy-packetline :
271
274
etc/ copy-packetline.sh
0 commit comments