-
Notifications
You must be signed in to change notification settings - Fork 1.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
🐛 (go/v3, go/v4-alpha): fix makefile targets do not re-install binaries when they are found in the project bin directory #2844
Conversation
|
Welcome @FotiadisM! |
Hi @FotiadisM. Thanks for your PR. I'm waiting for a kubernetes-sigs member to verify that this patch is reasonable to test. If it is, they should reply with Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
docs/book/src/component-config-tutorial/testdata/project/Makefile
Outdated
Show resolved
Hide resolved
docs/book/src/component-config-tutorial/testdata/project/Makefile
Outdated
Show resolved
Hide resolved
docs/book/src/component-config-tutorial/testdata/project/Makefile
Outdated
Show resolved
Hide resolved
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.
Thank you for the contribution 🥇
Could you just please address the nits and assign the CLA so that we can move forward here?
Just changed my commit to use |
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.
/ok-to-test
Great work 🥇
Thank you for the contribution and to raise that.
/hold @FotiadisM , it is faling because you did not regenerated the testdata dir. |
/retest |
/hold cancel |
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.
/lgtm
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: camilamacedo86, FotiadisM The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
@@ -124,9 +124,9 @@ $(KUSTOMIZE): $(LOCALBIN) | |||
.PHONY: controller-gen | |||
controller-gen: $(CONTROLLER_GEN) ## Download controller-gen locally if necessary. | |||
$(CONTROLLER_GEN): $(LOCALBIN) | |||
GOBIN=$(LOCALBIN) go install sigs.k8s.io/controller-tools/cmd/controller-gen@$(CONTROLLER_TOOLS_VERSION) | |||
test -s $(LOCALBIN)/controller-gen || GOBIN=$(LOCALBIN) go install sigs.k8s.io/controller-tools/cmd/controller-gen@$(CONTROLLER_TOOLS_VERSION) |
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.
Hi, I just came across this PR while fixing a similar issue in our operator's Makefile. I was wondering if these test commands should use the variables for each binary, such as: test -s $(CONTROLLER_GEN)
. If the user overrides the tool variable (e.g. CONTROLLER_GEN
), then this test will not work.
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 you are right, it should probably be changed to
$(CONTROLLER_GEN): $(LOCALBIN)
test -s $@ || GOBIN=$(LOCALBIN) go install sigs.k8s.io/controller-tools/cmd/controller-gen@$(CONTROLLER_TOOLS_VERSION)
Description
Change the Makefile targets controller-gen and envtest no longer try to download the binary when they can be found in the project/bin directory.
Motivation
Closes: #2843