1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
.PHONY: check fmt clippy test audit deny vet semver bench bench-history coverage build release doc fuzz msrv clean
# Run all CI checks locally
check: fmt clippy test audit deny
# Format check
fmt:
cargo fmt --all -- --check
# Lint (zero warnings)
clippy:
cargo clippy --all-features --all-targets -- -D warnings
# Run test suite
test:
cargo test --all-features
# Security audit
audit:
cargo audit
# Supply-chain checks
deny:
cargo deny check
# Dependency audit chain
vet:
cargo vet
# SemVer compatibility check (requires cargo-semver-checks)
semver:
cargo semver-checks check-release
# MSRV check
msrv:
cargo +1.89 check
cargo +1.89 test
# Run benchmarks (synthetic)
bench:
cargo bench --bench routing --bench providers --bench hot_path --bench e2e -- --noplot
# Run benchmarks with CSV history tracking
bench-history:
./scripts/bench-history.sh
# Coverage report (HTML + lcov)
coverage:
cargo llvm-cov --all-features --lcov --output-path lcov.info
cargo llvm-cov --all-features --html
# Fuzz deserialization paths (requires cargo-fuzz, nightly)
fuzz:
cargo +nightly fuzz run fuzz_inference_request -- -max_total_time=300
cargo +nightly fuzz run fuzz_message_content -- -max_total_time=300
# Build release
build:
cargo build --release
# Build and package release artifact
release:
@VERSION=$$(cat VERSION | tr -d '[:space:]'); \
cargo build --release; \
tar czf "hoosh-$${VERSION}-linux-amd64.tar.gz" -C target/release hoosh; \
sha256sum "hoosh-$${VERSION}-linux-amd64.tar.gz" > "hoosh-$${VERSION}-linux-amd64.tar.gz.sha256"; \
echo "Packaged hoosh-$${VERSION}-linux-amd64.tar.gz"
# Generate documentation (warnings as errors)
doc:
RUSTDOCFLAGS="-D warnings" cargo doc --no-deps --all-features
# Clean build artifacts
clean:
cargo clean
rm -f hoosh-*.tar.gz hoosh-*.sha256