From e87d9e639f4c7234a69859c9661e92f37cb99a54 Mon Sep 17 00:00:00 2001 From: Todd Short Date: Tue, 15 Jul 2025 10:28:33 -0400 Subject: [PATCH] When generating, delete only upstream targets Using `find .` will delete all files of the name, this has a wide blast radius downstream. Limit the set of `find` directories to those in upstream. Signed-off-by: Todd Short --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index fef152f723..410205a894 100644 --- a/Makefile +++ b/Makefile @@ -163,7 +163,7 @@ manifests: $(CONTROLLER_GEN) $(KUSTOMIZE) #EXHELP Generate WebhookConfiguration, .PHONY: generate generate: $(CONTROLLER_GEN) #EXHELP Generate code containing DeepCopy, DeepCopyInto, and DeepCopyObject method implementations. - @find . -name "zz_generated.deepcopy.go" -delete # Need to delete the files for them to be generated properly + @find api cmd hack internal -name "zz_generated.deepcopy.go" -delete # Need to delete the files for them to be generated properly $(CONTROLLER_GEN) --load-build-tags=$(GO_BUILD_TAGS) object:headerFile="hack/boilerplate.go.txt" paths="./..." .PHONY: verify