mirror of
https://github.com/ScuroNeko/mtg.git
synced 2026-08-31 12:04:03 +03:00
Update golangci-lint
This commit is contained in:
@@ -111,10 +111,15 @@ jobs:
|
||||
with:
|
||||
submodules: recursive
|
||||
|
||||
- name: Run linter
|
||||
uses: golangci/golangci-lint-action@v2
|
||||
- name: Setup Go
|
||||
uses: actions/setup-go@v2
|
||||
with:
|
||||
version: v1.44.2
|
||||
go-version: ^1.18
|
||||
|
||||
- name: Run linter
|
||||
uses: golangci/golangci-lint-action@v3
|
||||
with:
|
||||
version: v1.45.0
|
||||
|
||||
docker:
|
||||
name: Docker
|
||||
|
||||
+1
-1
@@ -9,4 +9,4 @@ format = "colored-line-number"
|
||||
|
||||
[linters]
|
||||
enable-all = true
|
||||
disable = ["ireturn", "varnamelen", "gochecknoglobals", "gas", "goerr113", "exhaustivestruct", "containedctx"]
|
||||
disable = ["thelper", "ireturn", "varnamelen", "gochecknoglobals", "gas", "goerr113", "exhaustivestruct", "containedctx"]
|
||||
|
||||
@@ -2,7 +2,7 @@ ROOT_DIR := $(shell dirname $(realpath $(lastword $(MAKEFILE_LIST))))
|
||||
IMAGE_NAME := mtg
|
||||
APP_NAME := $(IMAGE_NAME)
|
||||
|
||||
GOLANGCI_LINT_VERSION := v1.44.2
|
||||
GOLANGCI_LINT_VERSION := v1.45.0
|
||||
|
||||
VERSION := $(shell git describe --exact-match HEAD 2>/dev/null || git describe --tags --always)
|
||||
COMMON_BUILD_FLAGS := -trimpath -mod=readonly -ldflags="-extldflags '-static' -s -w -X 'main.version=$(VERSION)'"
|
||||
|
||||
@@ -19,7 +19,7 @@ func FuzzServerSend(f *testing.F) {
|
||||
Once().
|
||||
Run(func(args mock.Arguments) {
|
||||
message := make([]byte, len(data))
|
||||
handshakeData.decryptor.XORKeyStream(message, args.Get(0).([]byte))
|
||||
handshakeData.decryptor.XORKeyStream(message, args.Get(0).([]byte)) // nolint: forcetypeassert
|
||||
assert.Equal(t, message, data)
|
||||
})
|
||||
|
||||
@@ -45,7 +45,7 @@ func FuzzServerReceive(f *testing.F) {
|
||||
Run(func(args mock.Arguments) {
|
||||
message := make([]byte, len(data))
|
||||
handshakeData.encryptor.XORKeyStream(message, data)
|
||||
copy(args.Get(0).([]byte), message)
|
||||
copy(args.Get(0).([]byte), message) // nolint: forcetypeassert
|
||||
})
|
||||
|
||||
n, err := handshakeData.proxyConn.Read(buffer)
|
||||
|
||||
Reference in New Issue
Block a user