Update linter

License: MIT
Signed-off-by: Jakub Sztandera <kubuxu@protonmail.ch>
This commit is contained in:
Jakub Sztandera 2019-07-05 13:21:54 +02:00
parent fd7daf4a31
commit 71dfa38032
4 changed files with 5 additions and 3 deletions

View File

@ -17,6 +17,7 @@ workflows:
ci: ci:
jobs: jobs:
- go/lint: - go/lint:
golangci-lint-version: 1.17.1
executor: go/circleci-golang executor: go/circleci-golang
- go/test: - go/test:
executor: go/circleci-golang executor: go/circleci-golang

View File

@ -2,7 +2,7 @@ linters:
disable-all: true disable-all: true
enable: enable:
- vet - vet
- gofmt - goimports
- misspell - misspell
- goconst - goconst
- golint - golint
@ -13,6 +13,7 @@ linters:
- varcheck - varcheck
- structcheck - structcheck
- deadcode - deadcode
- scopelint
issues: issues:

View File

@ -28,7 +28,7 @@ import (
// can't really be identified by the returned type // can't really be identified by the returned type
type special struct{ id int } type special struct{ id int }
// nolint //nolint:golint
var ( var (
DefaultTransportsKey = special{0} // Libp2p option DefaultTransportsKey = special{0} // Libp2p option
PNetKey = special{1} // Option + multiret PNetKey = special{1} // Option + multiret

View File

@ -5,7 +5,7 @@ import (
logging "github.com/ipfs/go-log" logging "github.com/ipfs/go-log"
"github.com/libp2p/go-libp2p" "github.com/libp2p/go-libp2p"
"github.com/libp2p/go-libp2p-connmgr" connmgr "github.com/libp2p/go-libp2p-connmgr"
"github.com/libp2p/go-libp2p-core/crypto" "github.com/libp2p/go-libp2p-core/crypto"
"github.com/libp2p/go-libp2p-core/peer" "github.com/libp2p/go-libp2p-core/peer"
"github.com/libp2p/go-libp2p-core/peerstore" "github.com/libp2p/go-libp2p-core/peerstore"