mirror of https://github.com/CrimsonTome/tldr.git
parent
7113ea246c
commit
ffab1fa468
|
@ -0,0 +1,20 @@
|
|||
# cargo clean
|
||||
|
||||
> Remove generated artifacts in the `target` directory.
|
||||
> More information: <https://doc.rust-lang.org/cargo/commands/cargo-clean.html>.
|
||||
|
||||
- Remove the entire `target` directory:
|
||||
|
||||
`cargo clean`
|
||||
|
||||
- Remove documentation artifacts (the `target/doc` directory):
|
||||
|
||||
`cargo clean --doc`
|
||||
|
||||
- Remove release artifacts (the `target/release` directory):
|
||||
|
||||
`cargo clean --release`
|
||||
|
||||
- Remove artifacts in the directory of the given profile (in this case, `target/debug`):
|
||||
|
||||
`cargo clean --profile {{dev}}`
|
|
@ -0,0 +1,16 @@
|
|||
# cargo fmt
|
||||
|
||||
> Run `rustfmt` on all source files in a Rust project.
|
||||
> More information: <https://github.com/rust-lang/rustfmt>.
|
||||
|
||||
- Format all source files:
|
||||
|
||||
`cargo fmt`
|
||||
|
||||
- Check for formatting errors without writing to the files:
|
||||
|
||||
`cargo fmt --check`
|
||||
|
||||
- Pass arguments to each `rustfmt` call:
|
||||
|
||||
`cargo fmt -- {{rustfmt_args}}`
|
Loading…
Reference in New Issue