Skip to content

Commit 114e29c

Browse files
update golangci-lint to v2.5.0
Signed-off-by: dongjiang <[email protected]> update golangci-lint to v2.5.0 Signed-off-by: dongjiang <[email protected]> Update examples/tokenreview/tokenreview.go Update pkg/reconcile/reconcile.go Co-Authored-By: Christian Schlotter <[email protected]>
1 parent 961fc2c commit 114e29c

File tree

6 files changed

+6
-5
lines changed

6 files changed

+6
-5
lines changed

.github/workflows/golangci-lint.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,6 @@ jobs:
3434
- name: golangci-lint
3535
uses: golangci/golangci-lint-action@4afd733a84b1f43292c63897423277bb7f4313a9 # tag=v8.0.0
3636
with:
37-
version: v2.4.0
37+
version: v2.5.0
3838
args: --output.text.print-linter-name=true --output.text.colors=true --timeout 10m
3939
working-directory: ${{matrix.working-directory}}

.golangci.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,10 +22,12 @@ linters:
2222
- goconst
2323
- gocritic
2424
- gocyclo
25+
- godoclint
2526
- goprintffuncname
2627
- govet
2728
- importas
2829
- ineffassign
30+
- iotamixing
2931
- makezero
3032
- misspell
3133
- nakedret

examples/crd/pkg/groupversion_info.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ See the License for the specific language governing permissions and
1414
limitations under the License.
1515
*/
1616

17+
// Package pkg contains API Schema definitions for the chaosapps v1 API group
1718
// +kubebuilder:object:generate=true
1819
// +groupName=chaosapps.metamagical.io
1920
package pkg

examples/tokenreview/tokenreview.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ import (
2828
type authenticator struct {
2929
}
3030

31-
// authenticator admits a request by the token.
31+
// Handle admits a request by the token.
3232
func (a *authenticator) Handle(ctx context.Context, req authentication.Request) authentication.Response {
3333
if req.Spec.Token == "invalid" {
3434
return authentication.Unauthenticated("invalid is an invalid token", v1.UserInfo{})

pkg/log/zap/flags.go

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,8 +14,6 @@ See the License for the specific language governing permissions and
1414
limitations under the License.
1515
*/
1616

17-
// Package zap contains helpers for setting up a new logr.Logger instance
18-
// using the Zap logging framework.
1917
package zap
2018

2119
import (

pkg/reconcile/reconcile.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,7 @@ type terminalError struct {
174174
err error
175175
}
176176

177-
// This function will return nil if te.err is nil.
177+
// Unwrap returns nil if te.err is nil.
178178
func (te *terminalError) Unwrap() error {
179179
return te.err
180180
}

0 commit comments

Comments
 (0)