go scratch code for atproto
at main 43 lines 996 B view raw
1 2SHELL = /bin/bash 3.SHELLFLAGS = -o pipefail -c 4 5.PHONY: help 6help: ## Print info about all commands 7 @echo "Commands:" 8 @echo 9 @grep -E '^[a-zA-Z0-9_-]+:.*?## .*$$' $(MAKEFILE_LIST) | awk 'BEGIN {FS = ":.*?## "}; {printf " \033[01;32m%-20s\033[0m %s\n", $$1, $$2}' 10 11.PHONY: build 12build: ## Build all executables 13 go build ./cmd/handlr 14 go build ./cmd/lexidex 15 go build ./cmd/glot 16 17.PHONY: all 18all: build 19 20.PHONY: test 21test: ## Run tests 22 go test ./... 23 24.PHONY: coverage-html 25coverage-html: ## Generate test coverage report and open in browser 26 go test ./... -coverpkg=./... -coverprofile=test-coverage.out 27 go tool cover -html=test-coverage.out 28 29.PHONY: lint 30lint: ## Verify code style and run static checks 31 go vet ./... 32 test -z $(gofmt -l ./...) 33 34.PHONY: fmt 35fmt: ## Run syntax re-formatting (modify in place) 36 go fmt ./... 37 38.PHONY: check 39check: ## Compile everything, checking syntax (does not output binaries) 40 go build ./... 41 42.env: 43 if [ ! -f ".env" ]; then cp example.dev.env .env; fi