autogits/bots-common/Makefile
2024-11-07 18:25:35 +01:00

16 lines
410 B
Makefile

all: build
api.json:
curl -o api.json https://src.opensuse.org/swagger.v1.json
gitea-generated/client/gitea_api_client.go:: api.json
[ -d gitea-generated ] || mkdir gitea-generated
podman run --rm -v $$(pwd):/api ghcr.io/go-swagger/go-swagger generate client -f /api/api.json -t /api/gitea-generated
api: gitea-generated/client/gitea_api_client.go mock_gitea_utils.go
go generate
build: api
go build