Files
cybertron-log-enricher/Makefile
varnit-goyal_navi 65092a5817 TP-5555/log-enricher
2024-08-13 08:19:50 +05:30

29 lines
646 B
Makefile

.PHONY: clean all
all: fmt lint build-log-enricher
run-local:
@bash ./scripts/run-local
setup:
go install github.com/golangci/golangci-lint/cmd/golangci-lint@latest
build-log-enricher:
go mod tidy && CGO_ENABLED=1 go build -ldflags="-s -w" -o out/log-enricher cmd/log-enricher/main.go
build-migrations:
go mod tidy && CGO_ENABLED=1 go build -ldflags="-s -w" -o out/migrations cmd/migrations/main.go
clean:
rm -rf out/
rm -f *.out
lint:
golangci-lint run
fmt:
@echo "Running fmt..."
@for p in $(ALL_PACKAGES); do \
go fmt $$p | { grep -vwE "exported (var|function|method|type|const) \S+ should have comment" || true; } \
done