-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathjustfile
More file actions
83 lines (62 loc) · 1.91 KB
/
justfile
File metadata and controls
83 lines (62 loc) · 1.91 KB
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
77
78
79
80
81
82
83
# SPDX-License-Identifier: AGPL-3.0-or-later
# Squirrel AI Primal — build automation
set dotenv-load := false
# Default recipe
default: check
# Full quality gate (CI equivalent)
ci: fmt-check clippy test doc
# Check compilation (fast feedback)
check:
cargo check --workspace --all-features
# Format check (no modification)
fmt-check:
cargo fmt --all -- --check
# Auto-format
fmt:
cargo fmt --all
# Clippy with full pedantic + nursery policy
clippy:
cargo clippy --workspace --all-targets --all-features -- -D warnings
# Run all tests (--all-features enables testing mocks for integration tests)
test:
cargo test --workspace --all-features
# Build documentation
doc:
cargo doc --workspace --no-deps
# Coverage report (requires cargo-llvm-cov)
coverage:
cargo llvm-cov --workspace --ignore-filename-regex 'target'
# Coverage with HTML report
coverage-html:
cargo llvm-cov --workspace --ignore-filename-regex 'target' --html
@echo "Report: target/llvm-cov/html/index.html"
# Build release binary (UniBin)
build-release:
cargo build --release -p squirrel
# Build ecoBin (static musl x86_64)
build-ecobin:
cargo build --release --target x86_64-unknown-linux-musl -p squirrel
# Build ecoBin for aarch64 (cross-compile)
build-ecobin-arm:
cargo build --release --target aarch64-unknown-linux-musl -p squirrel
# Build all ecoBin targets
build-ecobin-all: build-ecobin build-ecobin-arm
# Run the server
run-server *ARGS:
cargo run -p squirrel -- server {{ARGS}}
# Run doctor diagnostics
doctor:
cargo run -p squirrel -- doctor --comprehensive
# Dependency audit
audit:
cargo deny check
# Check for future-incompatible code
future-compat:
cargo report future-incompatibilities
# Clean build artifacts
clean:
cargo clean
# Count lines per file (check 1000-line limit)
line-check:
@find . -name "*.rs" -not -path "*/target/*" \
-exec wc -l {} + | sort -rn | head -20