-
Notifications
You must be signed in to change notification settings - Fork 23
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
add target to validate swagger with spectral #164
Conversation
Makefile
Outdated
@@ -197,6 +197,9 @@ ifeq (, $(shell which ginkgo)) | |||
$(call go-get-tool,$(GINKGO),github.com/onsi/ginkgo/ginkgo@v1.16.5) | |||
endif | |||
|
|||
validate-swagger: ## Validate swagger | |||
$(DOCKER) run -it --rm -v $(PWD)/.spectral.yaml:/tmp/.spectral.yaml -v $(PWD)/swagger.yaml:/tmp/swagger.yaml stoplight/spectral lint --ruleset "/tmp/.spectral.yaml" /tmp/swagger.yaml |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
pls remove trailing whitespace
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Could the use of mktemp
be more appropriate and consistent with the rest of the Makefile
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
don't think it is needed here. the file should exist only inside a container that will be removed after the execution ends.
@tupyy Welcome and Thank you! :-) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@tupyy Welcome :)
@masayag @gciavarrini Thank you! :) |
This PR address the issue #155.
The rules set is the default one for OpenAPI.