From 7402fc23db95fe439d439cd1a792c725e510057e Mon Sep 17 00:00:00 2001 From: PatrickLaabs Date: Fri, 21 Nov 2025 09:51:20 +0100 Subject: [PATCH] Denying deprecated pointer package in golangci-linters config --- hack/golangci-hints.yaml | 6 ++++++ hack/golangci.yaml | 6 ++++++ hack/golangci.yaml.in | 6 ++++++ 3 files changed, 18 insertions(+) diff --git a/hack/golangci-hints.yaml b/hack/golangci-hints.yaml index 5d54b511c5c..c47c3046875 100644 --- a/hack/golangci-hints.yaml +++ b/hack/golangci-hints.yaml @@ -378,6 +378,12 @@ linters: # - fruit depguard: rules: + utils: + files: + - $all + deny: + - pkg: "k8s.io/utils/pointer" + desc: "k8s.io/utils/pointer shall no longer be used, please use k8s.io/utils/ptr." go-cmp: files: - $all diff --git a/hack/golangci.yaml b/hack/golangci.yaml index fa853d4afa5..adbfeee2ed9 100644 --- a/hack/golangci.yaml +++ b/hack/golangci.yaml @@ -387,6 +387,12 @@ linters: # - fruit depguard: rules: + utils: + files: + - $all + deny: + - pkg: "k8s.io/utils/pointer" + desc: "k8s.io/utils/pointer shall no longer be used, please use k8s.io/utils/ptr." go-cmp: files: - $all diff --git a/hack/golangci.yaml.in b/hack/golangci.yaml.in index 13da763a9a8..b3c95a4442f 100644 --- a/hack/golangci.yaml.in +++ b/hack/golangci.yaml.in @@ -199,6 +199,12 @@ linters: {{include "hack/kube-api-linter/kube-api-linter.yaml" | indent 10 | trim}} depguard: rules: + utils: + files: + - $all + deny: + - pkg: "k8s.io/utils/pointer" + desc: "k8s.io/utils/pointer shall no longer be used, please use k8s.io/utils/ptr." go-cmp: files: - $all