-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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 fmt-check
to make checks-backend
for CI
#21452
Conversation
Instead of adding another drone step, just add it to Line 337 in 9dc264a
E.g. checks-backend: tidy-check swagger-check fmt-check swagger-validate |
a4cbd40
to
cb70df4
Compare
fmt-check
to Drone pipelinefmt-check
to make checks-backend
for CI
cb70df4
to
247a05a
Compare
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.
I think we also need to add fmt
to the dependencies of fmt-check
, otherwise it will never see a diff.
Hmmm, I see, perhaps having a different way to handle |
I'm not sure what you're getting at, but we use the same strategy already for other things like So I think having |
Suppose I commit a changeset with wrongly formatted Go code and correctly formatted templates, |
Ah, I see |
I suppose you can just reduce to a single @diff=$$(git diff $(GO_SOURCES) templates); \
if [ -n "$$diff" ]; then \
echo "Please run 'make fmt' and commit the result:"; \
echo "$${diff}"; \
exit 1; \
fi |
How about we merge this as-is and open an issue on how to handle the actual |
Signed-off-by: Yarden Shoham <[email protected]>
247a05a
to
7367168
Compare
#21458 for the proposed enhancements. Fine with me to land this before. |
I suggest we just land #21458 instead of this. The order of targets is different here, so if this lands my PR would conflict. |
make fmt
#21437 I realized the build system isn't actually checking that the code is formatted