Skip to content
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

replace cilium/customvet by cilium/linters #26755

Merged
merged 1 commit into from
Jul 12, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
9 changes: 4 additions & 5 deletions contrib/scripts/custom-vet-check.sh
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,7 @@
# SPDX-License-Identifier: Apache-2.0
# Copyright Authors of Cilium

# "customvet" is a custom go vet tool that can be found at
# https://github.com/cilium/customvet
# It performs custom static analysis checks checks for the
# cilium repository.
"$GO" run github.com/cilium/customvet -timeafter.ignore inctimer -readall.ignore safeio ./...
# Cilium implements custom linters that can be found at
# https://github.com/cilium/linters
# They performs custom static analysis checks.
"$GO" run github.com/cilium/linters -timeafter.ignore inctimer -readall.ignore safeio ./...
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,10 @@ require (
github.com/blang/semver/v4 v4.0.0
github.com/cilium/checkmate v1.0.3
github.com/cilium/coverbee v0.3.2
github.com/cilium/customvet v0.0.0-20221207181232-aa8731fa2d27
github.com/cilium/deepequal-gen v0.0.0-20230330134849-754271daeec2
github.com/cilium/ebpf v0.11.0
github.com/cilium/fake v0.4.0
github.com/cilium/linters v0.0.0-20230711081823-012f25fa2197
github.com/cilium/lumberjack/v2 v2.3.0
github.com/cilium/proxy v0.0.0-20230623092907-8fddead4e52c
github.com/cilium/workerpool v1.2.0
Expand Down
4 changes: 2 additions & 2 deletions go.sum

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 2 additions & 4 deletions pkg/inctimer/inctimer.go
Original file line number Diff line number Diff line change
Expand Up @@ -73,10 +73,8 @@ func (it *incTimer) After(d time.Duration) <-chan time.Time {
return it.t.C
}

// After wraps the time.After function to get
// around the customvet warning for cases
// where it is inconvenient to use the instantiated
// version.
// After wraps the time.After function to get around the /timeafter linter
// warning for cases where it is inconvenient to use the instantiated version.
func After(d time.Duration) <-chan time.Time {
return time.After(d)
}
2 changes: 1 addition & 1 deletion tools/tools.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@
package tools

import (
_ "github.com/cilium/customvet"
_ "github.com/cilium/deepequal-gen"
_ "github.com/cilium/linters"
_ "github.com/gogo/protobuf/gogoproto" // Used for protobuf generation of pkg/k8s/types/slim/k8s
_ "golang.org/x/tools/cmd/goimports"
_ "k8s.io/code-generator"
Expand Down
7 changes: 0 additions & 7 deletions vendor/github.com/cilium/customvet/README.md

This file was deleted.

12 changes: 0 additions & 12 deletions vendor/github.com/cilium/customvet/main.go

This file was deleted.

92 changes: 92 additions & 0 deletions vendor/github.com/cilium/linters/.golangci.yml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

25 changes: 25 additions & 0 deletions vendor/github.com/cilium/linters/README.md

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

16 changes: 16 additions & 0 deletions vendor/github.com/cilium/linters/ioreadall/doc.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

16 changes: 16 additions & 0 deletions vendor/github.com/cilium/linters/main.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

13 changes: 13 additions & 0 deletions vendor/github.com/cilium/linters/timeafter/doc.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 5 additions & 5 deletions vendor/modules.txt
Original file line number Diff line number Diff line change
Expand Up @@ -178,11 +178,6 @@ github.com/cilium/checkmate
github.com/cilium/coverbee
github.com/cilium/coverbee/pkg/cparser
github.com/cilium/coverbee/pkg/verifierlog
# github.com/cilium/customvet v0.0.0-20221207181232-aa8731fa2d27
## explicit; go 1.19
github.com/cilium/customvet
github.com/cilium/customvet/analysis/ioreadall
github.com/cilium/customvet/analysis/timeafter
# github.com/cilium/deepequal-gen v0.0.0-20230330134849-754271daeec2
## explicit; go 1.20
github.com/cilium/deepequal-gen
Expand All @@ -205,6 +200,11 @@ github.com/cilium/ebpf/rlimit
# github.com/cilium/fake v0.4.0
## explicit; go 1.19
github.com/cilium/fake
# github.com/cilium/linters v0.0.0-20230711081823-012f25fa2197
## explicit; go 1.19
github.com/cilium/linters
github.com/cilium/linters/ioreadall
github.com/cilium/linters/timeafter
# github.com/cilium/lumberjack/v2 v2.3.0
## explicit; go 1.13
github.com/cilium/lumberjack/v2
Expand Down