Skip to content

Commit 6661045

Browse files
committed
[golangci-lint] add local-prefixes to linters-settings of goimports
Signed-off-by: Tariq Ibrahim <[email protected]>
1 parent c5bb1d4 commit 6661045

File tree

81 files changed

+93
-24
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

81 files changed

+93
-24
lines changed

.golangci.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,8 @@ linters:
4040
- whitespace
4141

4242
linters-settings:
43+
goimports:
44+
local-prefixes: sigs.k8s.io/controller-runtime
4345
govet:
4446
enable-all: true
4547
disable:

alias.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ package controllerruntime
1919
import (
2020
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
2121
"k8s.io/apimachinery/pkg/runtime/schema"
22+
2223
"sigs.k8s.io/controller-runtime/pkg/builder"
2324
"sigs.k8s.io/controller-runtime/pkg/client/config"
2425
"sigs.k8s.io/controller-runtime/pkg/controller/controllerutil"

pkg/builder/builder_suite_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,12 +26,12 @@ import (
2626
metav1 "k8s.io/apimachinery/pkg/apis/meta/v1"
2727
"k8s.io/apimachinery/pkg/runtime/schema"
2828
"k8s.io/client-go/rest"
29-
metricsserver "sigs.k8s.io/controller-runtime/pkg/metrics/server"
3029

3130
"sigs.k8s.io/controller-runtime/pkg/envtest"
3231
"sigs.k8s.io/controller-runtime/pkg/internal/testing/addr"
3332
logf "sigs.k8s.io/controller-runtime/pkg/log"
3433
"sigs.k8s.io/controller-runtime/pkg/log/zap"
34+
metricsserver "sigs.k8s.io/controller-runtime/pkg/metrics/server"
3535
"sigs.k8s.io/controller-runtime/pkg/webhook"
3636
)
3737

pkg/cache/cache_suite_test.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -23,6 +23,7 @@ import (
2323
. "github.com/onsi/gomega"
2424
"k8s.io/client-go/kubernetes"
2525
"k8s.io/client-go/rest"
26+
2627
"sigs.k8s.io/controller-runtime/pkg/envtest"
2728
logf "sigs.k8s.io/controller-runtime/pkg/log"
2829
"sigs.k8s.io/controller-runtime/pkg/log/zap"

pkg/cache/defaulting_test.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ import (
3333
"k8s.io/client-go/rest"
3434
"k8s.io/client-go/tools/cache"
3535
"k8s.io/utils/ptr"
36+
3637
"sigs.k8s.io/controller-runtime/pkg/client"
3738
)
3839

pkg/cache/delegating_by_gvk_cache.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@ import (
2525

2626
"k8s.io/apimachinery/pkg/runtime"
2727
"k8s.io/apimachinery/pkg/runtime/schema"
28+
2829
"sigs.k8s.io/controller-runtime/pkg/client"
2930
"sigs.k8s.io/controller-runtime/pkg/client/apiutil"
3031
)

pkg/cache/internal/informers.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ import (
3636
"k8s.io/client-go/metadata"
3737
"k8s.io/client-go/rest"
3838
"k8s.io/client-go/tools/cache"
39+
3940
"sigs.k8s.io/controller-runtime/pkg/client/apiutil"
4041
"sigs.k8s.io/controller-runtime/pkg/internal/syncs"
4142
)

pkg/certwatcher/certwatcher.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ import (
2929
kerrors "k8s.io/apimachinery/pkg/util/errors"
3030
"k8s.io/apimachinery/pkg/util/sets"
3131
"k8s.io/apimachinery/pkg/util/wait"
32+
3233
"sigs.k8s.io/controller-runtime/pkg/certwatcher/metrics"
3334
logf "sigs.k8s.io/controller-runtime/pkg/internal/log"
3435
)

pkg/client/apiutil/apimachinery_test.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -28,6 +28,7 @@ import (
2828
"k8s.io/client-go/discovery"
2929
"k8s.io/client-go/kubernetes/scheme"
3030
"k8s.io/client-go/rest"
31+
3132
"sigs.k8s.io/controller-runtime/pkg/client"
3233
"sigs.k8s.io/controller-runtime/pkg/client/apiutil"
3334
)

pkg/client/client_rest_resources.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ import (
2727
"k8s.io/apimachinery/pkg/runtime/schema"
2828
"k8s.io/apimachinery/pkg/runtime/serializer"
2929
"k8s.io/client-go/rest"
30+
3031
"sigs.k8s.io/controller-runtime/pkg/client/apiutil"
3132
)
3233

0 commit comments

Comments
 (0)