-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
refactor/ci tasks improvement new #5303
Changes from 4 commits
532abf7
d78fe66
8f28349
a90c19d
9e101ee
d91ea65
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -89,9 +89,28 @@ $(pGen)/%.go: $(MYGOBIN)/pluginator $(MYGOBIN)/goimports | |
$(MYGOBIN)/goimports -w $*.go \ | ||
) | ||
|
||
# Target is for debugging. | ||
# Generate builtin plugins | ||
.PHONY: generate-kustomize-builtin-plugins | ||
generate-kustomize-builtin-plugins: $(builtinplugins) | ||
generate-kustomize-builtin-plugins: $(builtplugins) | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Maybe I think it is better to separate a step of generate and a step of diff check. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I see your point. Do you know if diff check will be called anywhere else? Since the context is strictly limited to builtin plugins maybe I should use There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I imagine making a new |
||
for plugin in $(abspath $(wildcard $(pSrc)/*)); do \ | ||
echo "generating $${plugin} ..."; \ | ||
set -e; \ | ||
cd $${plugin}; \ | ||
go generate pluginator .; \ | ||
done; \ | ||
cd ../../../; \ | ||
make no-diff \ | ||
|
||
# Check for diff, if diff is found, throw error code 1 | ||
.PHONY: no-diff | ||
no-diff: $(builtplugins) | ||
for file in $(abspath $(builtinplugins)); do \ | ||
echo "Checking for diff... $${file}" ; \ | ||
set -e ; \ | ||
if [ "`git diff $${file} | wc -c`" -gt 0 ]; then\ | ||
echo "Error(1): diff found on $${file}"; exit 1; \ | ||
fi \ | ||
done | ||
|
||
.PHONY: build-kustomize-external-go-plugin | ||
build-kustomize-external-go-plugin: | ||
|
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.
Do you have any specific reason to remove the hyphen here?
I think it is better to use a unified name here.
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.
No issue here, yes we can go with unified name