# Bump all deps, including incompatible version upgrades
bump:
just ensure-command cargo-upgrade
cargo update
cargo upgrade --incompatible
# Run the test suite with all feature combinations
test:
cargo test --all-features --doc
cargo test --doc
lint:
just ensure-command cargo-deny
cargo +nightly fmt --all -- --check
taplo format --check
cargo clippy --tests --workspace --all -- -D warnings
cargo deny check
RUSTDOCFLAGS='-D warnings' cargo doc --document-private-items --no-deps
format:
just ensure-command taplo
cargo +nightly fmt
taplo format
# Ensures that one or more required commands are installed
ensure-command +command:
#!/usr/bin/env bash
set -euo pipefail
read -r -a commands <<< "{{ command }}"
for cmd in "${commands[@]}"; do
if ! command -v "$cmd" > /dev/null 2>&1 ; then
printf "Couldn't find required executable '%s'\n" "$cmd" >&2
exit 1
fi
done