From 17d7ea7876afd037bb9ea870ae058f603ddf89ad Mon Sep 17 00:00:00 2001 From: Steve Kriss Date: Thu, 27 Feb 2020 10:05:56 -0700 Subject: [PATCH] add modules & verify-modules make targets Signed-off-by: Steve Kriss --- Makefile | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index e5e5ecda9..66a5a6d10 100644 --- a/Makefile +++ b/Makefile @@ -226,7 +226,17 @@ clean: rm -rf .go _output docker rmi $(BUILDER_IMAGE) -ci: all verify test +.PHONY: modules +modules: + go mod tidy + +.PHONY: verify-modules +verify-modules: modules + @if !(git diff --quiet HEAD -- go.sum go.mod); then \ + echo "go module files are out of date, please commit the changes to go.mod and go.sum"; exit 1; \ + fi + +ci: verify-modules verify all test changelog: hack/changelog.sh