Rebuild from a clean state for reproducibility.

Section: Local packaging

Clean before a release build

bash
bash
cargo clean && cargo build --release
Explanation

Helps surface missing tracked files or stale artifacts before release.

Learn the surrounding workflow

Compare similar commands or jump into common fixes when this command is part of a bigger troubleshooting path.

Related commands

Same sheet · prioritizing Local packaging
Create a package tarball
Build the package as it would be published.
OpenIn sheetbashsame section
List packaged files
Show what files would go into the package.
OpenIn sheetbashsame section
Validate publish without uploading
Run all publish checks without actually publishing.
OpenIn sheetbashsame section
Build an optimized release binary
Compile the release artifact for shipping.
OpenIn sheetbash2 tag match
Build a mostly static Linux binary
Compile against the musl target.
OpenIn sheetbash2 tag match
Read current package version
Inspect the manifest version before tagging a release.
OpenIn sheetbash2 tag match