- Generated HTML now in site/blog/posts/ (gitignored) - CI workflow runs pandoc + make blog before deploy - Updated all internal blog links to /blog/posts/ path - blog/*.md remains the source of truth Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
47 lines
1000 B
Makefile
47 lines
1000 B
Makefile
.PHONY: all build lint fmt check audit test bench clean deploy blog
|
|
|
|
all: lint build test
|
|
|
|
build:
|
|
cargo build
|
|
|
|
lint: fmt check audit
|
|
|
|
fmt:
|
|
cargo fmt --check
|
|
|
|
check:
|
|
cargo clippy -- -D warnings
|
|
|
|
audit:
|
|
cargo audit
|
|
|
|
test:
|
|
cargo test
|
|
|
|
bench:
|
|
cargo bench
|
|
|
|
blog:
|
|
@mkdir -p site/blog/posts
|
|
@for f in blog/*.md; do \
|
|
name=$$(basename "$$f" .md); \
|
|
pandoc "$$f" --template=site/blog-template.html -o "site/blog/posts/$$name.html"; \
|
|
echo " $$f → site/blog/posts/$$name.html"; \
|
|
done
|
|
|
|
clean:
|
|
cargo clean
|
|
|
|
deploy:
|
|
cargo build --release
|
|
sudo cp target/release/numa /usr/local/bin/numa
|
|
ifeq ($(shell uname -s),Darwin)
|
|
sudo codesign -f -s - /usr/local/bin/numa
|
|
sudo kill $$(pgrep -f /usr/local/bin/numa) 2>/dev/null || true
|
|
else
|
|
sudo systemctl restart numa 2>/dev/null || sudo kill $$(pgrep -f /usr/local/bin/numa) 2>/dev/null || true
|
|
endif
|
|
@sleep 1
|
|
@dig @127.0.0.1 google.com +short +time=3 > /dev/null && echo "Service restarted successfully" || echo "Warning: DNS not responding yet"
|