Root check now loops app then blogex then the pin check, mirroring the shape the Lens pass will use. blogex gains a check target (compile with warnings fatal + format); credo is a marked slot until its dep exists, and the gate never claims a sensor it did not run.
69 lines
1.7 KiB
Makefile
69 lines
1.7 KiB
Makefile
# Makefile for Firehose monorepo
|
|
|
|
MISE_BIN ?= mise
|
|
|
|
.PHONY: check precommit deps compile test test-elisp format
|
|
|
|
# Cheap static gate over both apps, cheapest first. No database, no coverage:
|
|
# this is the loop you run freely while working and before every commit.
|
|
check:
|
|
@echo "==> check: app (credo --strict, format)"
|
|
@$(MAKE) -C app MISE_BIN=$(MISE_BIN) check
|
|
@echo "==> check: blogex (compile, format)"
|
|
@$(MAKE) -C blogex MISE_BIN=$(MISE_BIN) check
|
|
@echo "==> check: toolchain pins"
|
|
@bash scripts/check-pins.sh
|
|
|
|
# Precommit target for CI/pre-commit hooks
|
|
precommit: check
|
|
|
|
# Sync dependencies
|
|
deps:
|
|
@make -C app deps
|
|
|
|
# Compile the project
|
|
compile:
|
|
@make -C app compile
|
|
|
|
# Run tests (app suite + blogex library suite)
|
|
test:
|
|
@make -C app test
|
|
@make -C blogex test
|
|
|
|
# Run Emacs Lisp tests for roam-export-blog (requires emacs on PATH)
|
|
test-elisp:
|
|
emacs --batch -Q -l org -l ox-md -l scripts/roam-export-blog.el -l scripts/roam-export-blog-test.el -f ert-run-tests-batch-and-exit
|
|
|
|
# Format code
|
|
format:
|
|
@make -C app format
|
|
|
|
# Serve the app
|
|
serve:
|
|
@cd app && mix phx.server
|
|
|
|
# Run Playwright browser-based tests (requires running server)
|
|
# Set PLAYWRIGHT_BASE_URL to point at the running Phoenix app
|
|
playwright:
|
|
@make -C app playwright
|
|
|
|
# Run Playwright in UI mode (headed browser)
|
|
playwright-ui:
|
|
@make -C app playwright-ui
|
|
|
|
# Run Playwright against Docker Chrome container (must be running)
|
|
playwright-docker:
|
|
@make -C app playwright-docker
|
|
|
|
# Full e2e workflow: start Chrome container, run tests, stop container
|
|
playwright-full:
|
|
@make -C app playwright-full
|
|
|
|
# Start Docker Chrome container
|
|
playwright-docker-start:
|
|
@make -C app playwright-docker-start
|
|
|
|
# Stop Docker Chrome container
|
|
playwright-docker-stop:
|
|
@make -C app playwright-docker-stop
|