Merge rust-bitcoin/rust-bitcoin#2326: Improve the `justfile`

61f8bab65f just: Add quick and dirty CI command (Tobin C. Harding)
e185fe46df just: Lint with nightly toolchain (Tobin C. Harding)

Pull request description:

  Improve the `justfile` by doing:

  - Update linter toolchain
  - Add `just sane` to run a minimal set of checks/tests that can be used pre-push but is not as slow as using `DO_FEATURE_MATRIX=true contrib/test.sh`.

ACKs for top commit:
  apoelstra:
    ACK 61f8bab65f
  Kixunil:
    ACK 61f8bab65f

Tree-SHA512: 730874f0381db9ae30052ad6511805f76ae5c13c4c5cc5ad272430cf7e67cfbe7b288aa6dc47035ff5e8e42e03d3e4a3bf9d3e9a072c9aa922f9df62c43850b3
This commit is contained in:
Andrew Poelstra 2024-01-27 16:42:34 +00:00
commit a38cdd520f
No known key found for this signature in database
GPG Key ID: C588D63CE41B97C1
1 changed files with 16 additions and 1 deletions

View File

@ -11,12 +11,27 @@ check:
# Lint everything.
lint:
cargo clippy --workspace --all-targets --all-features -- --deny warnings
cargo +nightly clippy --workspace --all-targets --all-features -- --deny warnings
# Check the formatting
format:
cargo +nightly fmt --all --check
# Quick and dirty CI useful for pre-push checks.
sane: lint
cargo test --quiet --workspace --all-targets --no-default-features > /dev/null || exit 1
cargo test --quiet --workspace --all-targets > /dev/null || exit 1
cargo test --quiet --workspace --all-targets --all-features > /dev/null || exit 1
# Docs tests (these don't run when testing from workspace root)
cargo test --quiet --manifest-path bitcoin/Cargo.toml --doc > /dev/null || exit 1
cargo test --quiet --manifest-path hashes/Cargo.toml --doc > /dev/null || exit 1
cargo test --quiet --manifest-path io/Cargo.toml --doc > /dev/null || exit 1
cargo test --quiet --manifest-path units/Cargo.toml --doc > /dev/null || exit 1
# Make an attempt to catch feature gate problems in doctests
cargo test --manifest-path bitcoin/Cargo.toml --doc --no-default-features > /dev/null || exit 1
# Update the recent and minimal lock files.
update-lock-files:
contrib/update-lock-files.sh