-
Notifications
You must be signed in to change notification settings - Fork 38.7k
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
hack/boilerplate: added regex to strip Python shebang #79448
hack/boilerplate: added regex to strip Python shebang #79448
Conversation
Hi @falcon78921. Thanks for your PR. I'm waiting for a kubernetes 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. |
/ok-to-test |
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.
thanks for doing this, few nits
hack/boilerplate/boilerplate.py
Outdated
@@ -102,6 +102,9 @@ def file_passes(filename, refs, regexs): | |||
elif extension == "sh": | |||
p = regexs["shebang"] | |||
(data, found) = p.subn("", data, 1) | |||
elif extension == "py": |
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.
pull into above if?
elif extension in ["sh", "py"]:
hack/boilerplate/boilerplate.py
Outdated
@@ -205,7 +208,7 @@ def get_regexs(): | |||
regexs["date"] = re.compile(get_dates()) | |||
# strip // +build \n\n build constraints | |||
regexs["go_build_constraints"] = re.compile(r"^(// \+build.*\n)+\n", re.MULTILINE) | |||
# strip #!.* from shell scripts | |||
# strip #!.* from shell scripts & Python scripts too! |
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.
# strip #!.* from shell scripts & Python scripts too! | |
# strip #!.* from scripts |
Fixes Prow Build Error: Boilerplate header is wrong for: /home/prow/go/src/k8s.io/kubernetes/hack/update_owners.py Signed-off-by: James McClune <jmcclune@mcclunetechnologies.net>
b362a6b
to
452c7be
Compare
@spiffxp Done :) |
/test pull-kubernetes-kubemark-e2e-gce-big |
/test pull-kubernetes-e2e-gce |
/approve |
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: falcon78921, spiffxp 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 |
@spiffxp Thanks again! :) |
What type of PR is this?
/kind failing-test
What this PR does / why we need it:
Fixes Prow Build Error:
Boilerplate header is wrong for: /home/prow/go/src/k8s.io/kubernetes/hack/update_owners.py
In regards to #79190
Which issue(s) this PR fixes:
N/A
Special notes for your reviewer:
N/A
Does this PR introduce a user-facing change?: