.PHONY: check check-rust check-fixtures check-skill check-py check-ts check-go check-rs check-rb check-java bench bench-criterion bench-rag eval-skill
check: check-rust check-fixtures check-skill
check-rust:
cargo fmt --check
cargo clippy --all-targets -- -D warnings
cargo test
check-fixtures: check-py check-go check-rs check-rb check-java
check-py:
@echo "==> Checking Python fixtures..."
@find benchmarks/fixtures/webapp_py -name '*.py' -exec python3 -m py_compile {} +
@echo " OK"
check-ts:
@echo "==> Checking TypeScript fixtures..."
@cd benchmarks/fixtures/webapp_ts && npx tsc --noEmit --strict --esModuleInterop --skipLibCheck
@echo " OK"
check-go:
@echo "==> Checking Go fixtures..."
@cd benchmarks/fixtures/webapp_go && go build ./...
@echo " OK"
check-rs:
@echo "==> Checking Rust fixtures..."
@cd benchmarks/fixtures/webapp_rs && cargo check 2>/dev/null
@echo " OK"
check-rb:
@echo "==> Checking Ruby fixtures..."
@find benchmarks/fixtures/webapp_rb -name '*.rb' -exec ruby -c {} + > /dev/null
@echo " OK"
check-java:
@echo "==> Checking Java fixtures..."
@mkdir -p /tmp/cartog_java_check && cd benchmarks/fixtures/webapp_java && javac -sourcepath . $$(find . -name "*.java" | sort) -d /tmp/cartog_java_check
@echo " OK"
check-skill:
@echo "==> Checking skill tests..."
@bash skills/cartog/tests/test_ensure_indexed.sh
eval-skill:
bash skills/cartog/tests/eval.sh
bench:
./benchmarks/run.sh
bench-criterion:
cargo bench --bench queries
bench-rag:
cargo test --test rag_relevancy -- --nocapture
cargo build --release
CARTOG=$(CURDIR)/target/release/cartog ./benchmarks/run.sh --scenario 13