feat: add root Makefile for uniform cross-layer commands#71
Conversation
Provides a single entry point for setup, dev, test, build, lint, and tidy across backend, web, and mobile without needing to cd into each subdirectory.
📝 WalkthroughWalkthroughAdds cross-platform Makefile targets for setup, development, testing, building, linting, integration testing, and dependency tidying. ChangesMakefile targets
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
🧹 Nitpick comments (1)
Makefile (1)
26-27: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick winUse
$(MAKE)for recursive backend targets.Hardcoding
makehere drops the parent make binary/flags, so-j,-n, and otherMAKEFLAGSstop propagating tobackend. Prefer$(MAKE) -C backend ...instead.♻️ Proposed change
dev-backend: - cd backend && make watch + $(MAKE) -C backend watch @@ build-backend: - cd backend && make build + $(MAKE) -C backend build @@ itest-backend: - cd backend && make itest + $(MAKE) -C backend itestAlso applies to: 47-48, 57-58
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the rest with a brief reason, keep changes minimal, and validate. In `@Makefile` around lines 26 - 27, The recursive backend targets in Makefile currently invoke a hardcoded make, which prevents parent flags and MAKEFLAGS from propagating. Update the affected targets such as dev-backend (and the other matching backend targets) to use $(MAKE) with -C backend so they inherit the caller’s make binary and flags; keep the existing backend command arguments unchanged.
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Nitpick comments:
In `@Makefile`:
- Around line 26-27: The recursive backend targets in Makefile currently invoke
a hardcoded make, which prevents parent flags and MAKEFLAGS from propagating.
Update the affected targets such as dev-backend (and the other matching backend
targets) to use $(MAKE) with -C backend so they inherit the caller’s make binary
and flags; keep the existing backend command arguments unchanged.
Summary
Makefileso all common tasks can be run from the project root withoutcd-ing into each layermake setup/make devdelegate to the existingsetup.sh/setup.ps1anddev.sh/dev.ps1scripts (cross-platform)Targets
make setupsetup.sh/setup.ps1)make devdev.sh/dev.ps1)make dev-backend/make dev-webmake testmake test-backend/make test-web/make test-e2emake buildmake lintmake itest-backendmake tidygo mod tidy+pnpm installTest plan
make setuprunssetup.ps1on Windows /setup.shon Unixmake devrunsdev.ps1on Windows /dev.shon Unixmake lintpasses on a clean checkoutmake test-backendruns Go testsmake test-webruns VitestSummary by CodeRabbit