mirror of
https://github.com/go-gitea/gitea
synced 2024-12-22 16:44:26 +00:00
Add make command to validate swagger file (#4096)
Partial fix for #4088
This commit is contained in:
parent
0549762fd0
commit
28fb255d91
7
Makefile
7
Makefile
@ -100,6 +100,13 @@ swagger-check: generate-swagger
|
|||||||
exit 1; \
|
exit 1; \
|
||||||
fi;
|
fi;
|
||||||
|
|
||||||
|
.PHONY: swagger-validate
|
||||||
|
swagger-validate:
|
||||||
|
@hash swagger > /dev/null 2>&1; if [ $$? -ne 0 ]; then \
|
||||||
|
$(GO) get -u github.com/go-swagger/go-swagger/cmd/swagger; \
|
||||||
|
fi
|
||||||
|
swagger validate ./public/swagger.v1.json
|
||||||
|
|
||||||
.PHONY: errcheck
|
.PHONY: errcheck
|
||||||
errcheck:
|
errcheck:
|
||||||
@hash errcheck > /dev/null 2>&1; if [ $$? -ne 0 ]; then \
|
@hash errcheck > /dev/null 2>&1; if [ $$? -ne 0 ]; then \
|
||||||
|
Loading…
Reference in New Issue
Block a user