add swagger

This commit is contained in:
2025-12-20 17:36:36 +02:00
parent f0d7d79e0f
commit bd06d071b2

View File

@@ -20,7 +20,7 @@ imports-tools:
go install golang.org/x/tools/cmd/goimports@latest; \
fi
.PHONY: all build run test lint fmt imports
.PHONY: all swag build run test lint fmt imports
all: build
@@ -30,6 +30,12 @@ run: build
BUILD_PARAMS = -trimpath -ldflags "-X git.oblat.lv/alex/triggerssmith/internal/vars.Version=$(VERSION)"
build-with-swag: swag build
swag:
@echo "-- generating swagger docs"
@swag init -g cmd/serve.go
build:
@echo "-- building $(NAME)"
@go build $(BUILD_PARAMS) -o $(BINARY) $(ENTRY)