From: merge-script Date: Thu, 10 Jul 2025 02:13:09 +0000 (+0000) Subject: Merge bitcoindevkit/bdk#1979: feat: add `justfile` X-Git-Tag: bitcoind_rpc-0.21.0~13 X-Git-Url: http://internal-gitweb-vhost/script/%22https:/database/scripts/struct.CompressedPublicKey.html?a=commitdiff_plain;h=ff8f11438e5b85d9de83deecc3b20951a4155f5b;p=bdk Merge bitcoindevkit/bdk#1979: feat: add `justfile` 501766e7106f043d45b5ab6d29e9af83d6590e13 feat: add `justfile` (Luis Schwab) Pull request description: ### Description Closes #1967. This PR adds a `justfile`, updates the PR template to use it, and adds a section on the `README.md` to show available recipes. These are the implemented recipes: ```justfile alias b := build alias c := check alias f := fmt alias t := test alias p := pre-push _default: @just --list # Build the project build: cargo build # Check code: formatting, compilation, linting, and commit signature check: cargo +nightly fmt --all -- --check cargo check --workspace --all-features cargo clippy --all-features --all-targets -- -D warnings @[ "$(git log --pretty='format:%G?' -1 HEAD)" = "N" ] && \ echo "\n⚠️ Unsigned commit: BDK requires that commits be signed." || \ true # Format all code fmt: cargo +nightly fmt # Run all tests for all crates with all features enabled test: @just _test-bitcoind_rpc @just _test-chain @just _test-core @just _test-electrum @just _test-esplora @just _test-file_store @just _test-testenv _test-bitcoind_rpc: cargo test -p bdk_bitcoind_rpc --all-features _test-chain: cargo test -p bdk_chain --all-features _test-core: cargo test -p bdk_core --all-features _test-electrum: cargo test -p bdk_electrum --all-features _test-esplora: cargo test -p bdk_esplora --all-features _test-file_store: cargo test -p bdk_file_store --all-features _test-testenv: cargo test -p bdk_testenv --all-features # Run pre-push suite: format, check, and test pre-push: fmt check test ``` `check` will verify if `HEAD` was signed and echo that warning if not. It does not check all commits, but I think that checking only the last is a pretty good heuristic (who signs the last commit only?). Before pushing, one only needs to run `just p`. ### Checklists #### All Submissions: * [X] I've signed all my commits * [X] I followed the [contribution guidelines](https://github.com/bitcoindevkit/bdk/blob/master/CONTRIBUTING.md) * [X] I ran `just p` before pushing ACKs for top commit: ValuedMammal: ACK 501766e7106f043d45b5ab6d29e9af83d6590e13 evanlinjin: ACK 501766e7106f043d45b5ab6d29e9af83d6590e13 Tree-SHA512: b42109c7c3e01f529b794f37bacf8c6c2298243dd5f827c59ce74e7c64a4ef48eac84c4de86280bec828f56a81854c57458d9ea2b10acb83766fc1bdb34d24b6 --- ff8f11438e5b85d9de83deecc3b20951a4155f5b