docs(arch): integrate architecture validation into QA workflow
- Add arch-check, arch-check-file, arch-check-object Makefile targets - Include arch-check in QA target for CI integration - Update architecture-rules.md with CLI usage examples - Update code-quality.md with validation commands 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
35
Makefile
35
Makefile
@@ -1,7 +1,7 @@
|
||||
# Wizamart Multi-Tenant E-Commerce Platform Makefile
|
||||
# Cross-platform compatible (Windows & Linux)
|
||||
|
||||
.PHONY: install install-dev install-docs install-all dev test test-coverage lint format check docker-build docker-up docker-down clean help npm-install tailwind-dev tailwind-build
|
||||
.PHONY: install install-dev install-docs install-all dev test test-coverage lint format check docker-build docker-up docker-down clean help npm-install tailwind-dev tailwind-build arch-check arch-check-file arch-check-object
|
||||
|
||||
# Detect OS
|
||||
ifeq ($(OS),Windows_NT)
|
||||
@@ -224,7 +224,33 @@ verify-imports:
|
||||
@echo "Verifying critical imports..."
|
||||
$(PYTHON) scripts/verify_critical_imports.py
|
||||
|
||||
qa: format lint test-coverage docs-check
|
||||
arch-check:
|
||||
@echo "Running architecture validation..."
|
||||
$(PYTHON) scripts/validate_architecture.py
|
||||
|
||||
arch-check-file:
|
||||
ifeq ($(DETECTED_OS),Windows)
|
||||
@if "$(file)"=="" (echo Error: Please provide a file. Usage: make arch-check-file file="path/to/file.py") else ($(PYTHON) scripts/validate_architecture.py -f "$(file)")
|
||||
else
|
||||
@if [ -z "$(file)" ]; then \
|
||||
echo "Error: Please provide a file. Usage: make arch-check-file file=\"path/to/file.py\""; \
|
||||
else \
|
||||
$(PYTHON) scripts/validate_architecture.py -f "$(file)"; \
|
||||
fi
|
||||
endif
|
||||
|
||||
arch-check-object:
|
||||
ifeq ($(DETECTED_OS),Windows)
|
||||
@if "$(name)"=="" (echo Error: Please provide an object name. Usage: make arch-check-object name="company") else ($(PYTHON) scripts/validate_architecture.py -o "$(name)")
|
||||
else
|
||||
@if [ -z "$(name)" ]; then \
|
||||
echo "Error: Please provide an object name. Usage: make arch-check-object name=\"company\""; \
|
||||
else \
|
||||
$(PYTHON) scripts/validate_architecture.py -o "$(name)"; \
|
||||
fi
|
||||
endif
|
||||
|
||||
qa: format lint arch-check test-coverage docs-check
|
||||
@echo "Quality assurance checks completed!"
|
||||
|
||||
# =============================================================================
|
||||
@@ -388,9 +414,12 @@ help:
|
||||
@echo " lint - Lint and auto-fix with ruff + mypy"
|
||||
@echo " lint-strict - Lint without auto-fix + mypy"
|
||||
@echo " verify-imports - Verify critical imports haven't been removed"
|
||||
@echo " arch-check - Validate architecture patterns"
|
||||
@echo " arch-check-file file=\"path\" - Check a single file"
|
||||
@echo " arch-check-object name=\"company\" - Check all files for an entity"
|
||||
@echo " check - Format + lint + verify imports"
|
||||
@echo " ci - Full CI pipeline (strict)"
|
||||
@echo " qa - Quality assurance"
|
||||
@echo " qa - Quality assurance (includes arch-check)"
|
||||
@echo ""
|
||||
@echo "=== DOCUMENTATION ==="
|
||||
@echo " docs-serve - Start documentation server"
|
||||
|
||||
Reference in New Issue
Block a user