summaryrefslogtreecommitdiff
path: root/pkg/api/Makefile
diff options
context:
space:
mode:
Diffstat (limited to 'pkg/api/Makefile')
-rw-r--r--pkg/api/Makefile12
1 files changed, 10 insertions, 2 deletions
diff --git a/pkg/api/Makefile b/pkg/api/Makefile
index 3d70376df..915f0b9b3 100644
--- a/pkg/api/Makefile
+++ b/pkg/api/Makefile
@@ -1,5 +1,13 @@
+export GO111MODULE=off
+
SWAGGER_OUT ?= swagger.yaml
-swagger:
+.PHONY: ${SWAGGER_OUT}
+${SWAGGER_OUT}:
+ # generate doesn't remove file on error
+ rm -f ${SWAGGER_OUT}
swagger generate spec -o ${SWAGGER_OUT} -w ./
- cat tags.yaml >> swagger.yaml
+
+# TODO: when pass validation move it under swagger.
+validate:
+ swagger validate ${SWAGGER_OUT}