Contributing Development Setup - osama1998H/Moca GitHub Wiki
Development Setup
Clone, build, test, and lint the Moca framework.
Prerequisites
- Go 1.26+
- Docker (for integration tests)
- Node.js 22+ (for Desk frontend)
- golangci-lint v2 (for linting)
Clone & Build
git clone https://github.com/osama1998H/Moca.git
cd Moca
make build # Build all 5 binaries to bin/
Individual binaries:
make build-server # bin/moca-server
make build-worker # bin/moca-worker
make build-scheduler # bin/moca-scheduler
make build-moca # bin/moca
make build-outbox # bin/moca-outbox
Running Tests
make test # Unit tests with race detector
Integration Tests
Requires Docker for PostgreSQL, Redis, and Meilisearch:
docker-compose up -d # Start backing services
make test-integration # Run integration tests
make test-api-integration # API integration tests only
Linting
make lint # golangci-lint v2 (5m timeout)
Benchmarks
make bench # Run Tier 1 benchmarks
make bench-compare # Compare against saved baseline
make bench-save-baseline # Save current run as baseline
Go Workspace
The project uses go.work to compose modules:
go 1.26
use (
.
)