Skip to content

Commit e088ce9

Browse files
authored
When generating, delete only upstream targets (#2098)
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 <[email protected]>
1 parent c076365 commit e088ce9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ manifests: $(CONTROLLER_GEN) $(KUSTOMIZE) #EXHELP Generate WebhookConfiguration,
163163

164164
.PHONY: generate
165165
generate: $(CONTROLLER_GEN) #EXHELP Generate code containing DeepCopy, DeepCopyInto, and DeepCopyObject method implementations.
166-
@find . -name "zz_generated.deepcopy.go" -delete # Need to delete the files for them to be generated properly
166+
@find api cmd hack internal -name "zz_generated.deepcopy.go" -delete # Need to delete the files for them to be generated properly
167167
$(CONTROLLER_GEN) --load-build-tags=$(GO_BUILD_TAGS) object:headerFile="hack/boilerplate.go.txt" paths="./..."
168168

169169
.PHONY: verify

0 commit comments

Comments
 (0)