go-tools/Makefile
xuu 2e79ac4460
All checks were successful
Go Bump / bump (push) Successful in 39s
Go Test / test (push) Successful in 49s
Deploy / deploy (push) Successful in 1m34s
chore: add ignore
2023-10-15 09:09:11 -06:00

40 lines
686 B
Makefile

export PATH:=$(shell go env GOPATH)/bin:$(PATH)
export EV_DATA=mem:
export EV_HTTP=:8085
export WEBFINGER_DOMAINS=localhost
.DEFAULT_GOAL := air
-include local.mk
air: gen
ifeq (, $(shell which air))
go install github.com/cosmtrek/air@latest
endif
air .
run:
go build -buildvcs=true -o sour.is-tools ./cmd/ev && ./sour.is-tools
test:
go test -cover -race ./...
GQLS=gqlgen.yml
GQLS:=$(GQLS) $(wildcard app/*/*.graphqls)
GQLS:=$(GQLS) $(wildcard app/*/*.go)
GQLSRC=internal/graph/generated/generated.go
clean:
rm -f "$(GQLSRC)"
gen: gql
gql: $(GQLSRC)
$(GQLSRC): $(GQLS)
ifeq (, $(shell which gqlgen))
go install github.com/99designs/gqlgen@latest
endif
gqlgen
clean: