-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
41 lines (31 loc) · 775 Bytes
/
Makefile
File metadata and controls
41 lines (31 loc) · 775 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
.PHONY: all build test clean install deps
# Default target
all: deps build
build:
go build -o bin/cRelay-crdt-db ./cmd/main.go
# Install to GOPATH/bin
install: deps
go build -o $(GOPATH)/bin/cRelay-crdt-db ./cmd/main.go
# Run all tests
test: deps
go test -v ./...
# Run tests for specific package
test-handlers: deps
go test -v ./internal/api/handlers/...
# Run specific test file
test-event-handlers: deps
go test -v ./internal/api/handlers/event_handlers_test.go
# Run orbitdb package tests
test-orbitdb: deps
go test -v ./orbitdb/...
# Run specific orbitdb test file
test-orbitdb-adapter: deps
go test -v ./orbitdb/adapter_test.go
# Clean build artifacts
clean:
rm -rf bin/
go clean
# Install and update dependencies
deps:
go mod download
go mod tidy