demo:
	clear
	go fmt ./...
	go build -race -o ./bin_dev/demo ./cmd/demo/main.go
	./demo.sh
mod:
	clear
	go get -u ./...
	go mod tidy -compat=1.24.2
	go mod vendor
	go fmt ./...

.PHONY: test
test:
	clear
	go fmt ./...
	go test -race -shuffle=on -timeout=30s -coverprofile=./cover.out ./...
	go tool cover -func=./cover.out

.PHONY: lint
lint:
	clear
	go fmt  ./...
	go vet  ./...
	# go install honnef.co/go/tools/cmd/staticcheck@latest
	# staticcheck ./...
	# go install github.com/MakeNowJust/enumcase/cmd/enumcase@latest
	# enumcase ./...
	# go install github.com/golangci/golangci-lint/cmd/golangci-lint@latest
	# golangci-lint run ./...
	go install github.com/fzipp/gocyclo/cmd/gocyclo@latest
	gocyclo -over 11 .
	go install github.com/securego/gosec/cmd/gosec@latest
	gosec ./...