File tree 1 file changed +12
-1
lines changed
1 file changed +12
-1
lines changed Original file line number Diff line number Diff line change @@ -26,7 +26,7 @@ Install `cargo-machete` with cargo:
26
26
27
27
` cargo install cargo-machete `
28
28
29
- ## Example
29
+ ## Usage
30
30
31
31
Run cargo-machete in a directory that contains one or more Rust projects (using Cargo for
32
32
dependency management):
@@ -39,6 +39,17 @@ cd my-directory && cargo machete
39
39
cargo machete /absolute/path/to/my/directory
40
40
```
41
41
42
+ The ** return code** gives an indication whether unused dependencies have been found:
43
+
44
+ - 0 if machete found no unused dependencies,
45
+ - 1 if it found at least one unused dependency,
46
+ - 2 if there was an error during processing (in which case there's no indication whether any unused
47
+ dependency was found or not).
48
+
49
+ This can be used in CI situations.
50
+
51
+ ### False positives
52
+
42
53
To ignore a certain set of dependencies in a crate, add
43
54
` package.metadata.cargo-machete ` to ` Cargo.toml ` , and specify an ` ignored ` array:
44
55
You can’t perform that action at this time.
0 commit comments