-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathMakefile
More file actions
56 lines (43 loc) · 1.36 KB
/
Makefile
File metadata and controls
56 lines (43 loc) · 1.36 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
# Default configuration file; override with `make CONFIG=custom.toml run`
CONFIG ?= vein.toml
ADMIN_BIND ?= 127.0.0.1
ADMIN_PORT ?= 9400
.PHONY: help run admin dev stats cache-refresh check fmt clippy test build release
help:
@echo "Available targets:"
@echo " run Start the Vein proxy (cargo run -- serve)"
@echo " stats Show cache statistics"
@echo " cache-refresh Refresh the hot cache from SQLite"
@echo " admin Start the Loco admin dashboard"
@echo " check Type-check the workspace"
@echo " fmt Format the workspace"
@echo " clippy Lint with cargo clippy"
@echo " test Run the workspace tests"
@echo " build Build debug binaries"
@echo " release Build release binaries"
run:
cargo run -- serve --config $(CONFIG)
dev:
@if ! command -v cargo-watch >/dev/null 2>&1; then \
echo "cargo-watch is required for 'make dev' (install with 'cargo install cargo-watch')."; \
exit 1; \
fi
cargo watch -x "run -- serve --config $(CONFIG)"
stats:
cargo run -- stats --config $(CONFIG)
cache-refresh:
cargo run -- cache refresh --config $(CONFIG)
admin:
cargo run -p vein-admin -- --config $(CONFIG) --bind $(ADMIN_BIND) --port $(ADMIN_PORT)
check:
cargo check
fmt:
cargo fmt
clippy:
cargo clippy
test:
cargo test
build:
cargo build
release:
cargo build --release