From 40f2bebc71c2a7d49ff81bbc6d068872cb013c7f Mon Sep 17 00:00:00 2001 From: Radomir Vagner Date: Fri, 15 May 2026 09:34:34 +0200 Subject: [PATCH 1/2] UPSTREAM: : OCPBUGS-85614, disable usage of current copyright year --- Makefile | 3 ++- README.md | 2 ++ hack/generate-license-header.sh | 4 ++-- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/Makefile b/Makefile index 56a70044a5..deb4e7683d 100644 --- a/Makefile +++ b/Makefile @@ -113,7 +113,7 @@ test/coverage: tools: bin/aws bin/ct bin/eksctl bin/ginkgo bin/golangci-lint bin/gomplate bin/helm bin/kops bin/kubetest2 bin/mockgen bin/shfmt .PHONY: update -update: update/gofmt update/kustomize update/mockgen update/gomod update/shfmt update/generate-license-header +update: update/gofmt update/kustomize update/mockgen update/gomod update/shfmt @echo "All updates succeeded!" .PHONY: verify @@ -286,6 +286,7 @@ update/shfmt: bin/shfmt ./bin/shfmt -w -i 2 -d ./hack/ .PHONY: update/generate-license-header + update/generate-license-header: ./hack/generate-license-header.sh diff --git a/README.md b/README.md index e5c07e1c6d..4c8a9fe3d4 100644 --- a/README.md +++ b/README.md @@ -58,3 +58,5 @@ The EBS CSI Driver implements the [Container Storage Interface specification](ht * [Kubernetes Examples](/examples/kubernetes) * [Driver Uninstallation](docs/install.md#uninstalling-the-ebs-csi-driver) * [Development and Contributing](CONTRIBUTING.md) + + diff --git a/hack/generate-license-header.sh b/hack/generate-license-header.sh index cb759f1bee..a0ea8491c4 100755 --- a/hack/generate-license-header.sh +++ b/hack/generate-license-header.sh @@ -18,7 +18,7 @@ set -euo pipefail echo "Adding license header..." -current_year=$(date +%Y) +#current_year=$(date +%Y) # Carry: do not add license to files in vendor/ directory find . -type d \( -name "deploy" -o -name "charts" -o -name "vendor" \) -prune -o -type f \( -name "*.go" -o -name "*.sh" -o -name "*.yaml" -o -name "*.yml" \) -print | while read -r file; do case "$file" in @@ -30,6 +30,6 @@ find . -type d \( -name "deploy" -o -name "charts" -o -name "vendor" \) -prune - ;; esac if ! grep -q "The Kubernetes Authors." "$file"; then - echo -e "${comment_prefix} Copyright ${current_year} The Kubernetes Authors.\n${comment_prefix}\n${comment_prefix} Licensed under the Apache License, Version 2.0 (the 'License');\n${comment_prefix} you may not use this file except in compliance with the License.\n${comment_prefix} You may obtain a copy of the License at\n${comment_prefix}\n${comment_prefix} http://www.apache.org/licenses/LICENSE-2.0\n${comment_prefix}\n${comment_prefix} Unless required by applicable law or agreed to in writing, software\n${comment_prefix} distributed under the License is distributed on an 'AS IS' BASIS,\n${comment_prefix} WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n${comment_prefix} See the License for the specific language governing permissions and\n${comment_prefix} limitations under the License.\n" | cat - "$file" >temp && mv temp "$file" + echo -e "${comment_prefix} Copyright 2024 The Kubernetes Authors.\n${comment_prefix}\n${comment_prefix} Licensed under the Apache License, Version 2.0 (the 'License');\n${comment_prefix} you may not use this file except in compliance with the License.\n${comment_prefix} You may obtain a copy of the License at\n${comment_prefix}\n${comment_prefix} http://www.apache.org/licenses/LICENSE-2.0\n${comment_prefix}\n${comment_prefix} Unless required by applicable law or agreed to in writing, software\n${comment_prefix} distributed under the License is distributed on an 'AS IS' BASIS,\n${comment_prefix} WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n${comment_prefix} See the License for the specific language governing permissions and\n${comment_prefix} limitations under the License.\n" | cat - "$file" >temp && mv temp "$file" fi done From c93e6ec8e1f3f280dfeaecd45f7770ffe6de0a3a Mon Sep 17 00:00:00 2001 From: Radomir Vagner Date: Fri, 15 May 2026 15:32:17 +0200 Subject: [PATCH 2/2] UPSTREAM: : OCPBUGS-85614, disable usage of current copyright year --- Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Makefile b/Makefile index deb4e7683d..00c635da4b 100644 --- a/Makefile +++ b/Makefile @@ -113,7 +113,7 @@ test/coverage: tools: bin/aws bin/ct bin/eksctl bin/ginkgo bin/golangci-lint bin/gomplate bin/helm bin/kops bin/kubetest2 bin/mockgen bin/shfmt .PHONY: update -update: update/gofmt update/kustomize update/mockgen update/gomod update/shfmt +update: update/gofmt update/kustomize update/mockgen update/gomod update/shfmt update/generate-license-header @echo "All updates succeeded!" .PHONY: verify