forked from spf13/cobra
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
deprecate <1.12.x, use golangci-lint (spf13#876)
* deprecate go 1.10.x and 1.11.x * use golangci-lint in Travis CI * fix linting issues accordingly
- Loading branch information
Showing
31 changed files
with
435 additions
and
543 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
* text=auto |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -33,7 +33,11 @@ tags | |
|
||
*.exe | ||
cobra | ||
!cobra/ | ||
cobra.test | ||
|
||
.idea/ | ||
*.iml | ||
|
||
# test-generated files | ||
cobra/cmd/testproject |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
run: | ||
deadline: 5m | ||
|
||
linters: | ||
enable: | ||
- deadcode | ||
- errcheck | ||
- gas | ||
- goconst | ||
- goimports | ||
- golint | ||
- govet | ||
- ineffassign | ||
- interfacer | ||
- maligned | ||
- megacheck | ||
- structcheck | ||
- unconvert | ||
- varcheck | ||
enable-all: false | ||
disable-all: true | ||
# presets: | ||
# - bugs | ||
# - unused | ||
fast: false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,31 +1,27 @@ | ||
language: go | ||
|
||
stages: | ||
- diff | ||
- lint | ||
- test | ||
|
||
go: | ||
- 1.10.x | ||
- 1.11.x | ||
- 1.12.x | ||
- 1.13.x | ||
- tip | ||
|
||
env: | ||
- GO111MODULE=on | ||
|
||
matrix: | ||
allow_failures: | ||
- go: tip | ||
include: | ||
- stage: diff | ||
go: 1.12.x | ||
script: diff -u <(echo -n) <(gofmt -d -s .) | ||
env: GO111MODULE=on | ||
|
||
before_install: go get -u github.com/kyoh86/richgo | ||
|
||
script: | ||
- richgo test -v ./... | ||
- go build | ||
- if [ -z $NOVET ]; then | ||
diff -u <(echo -n) <(go vet . 2>&1 | grep -vE 'ExampleCommand|bash_completions.*Fprint'); | ||
fi | ||
|
||
matrix: | ||
allow_failures: | ||
- go: tip | ||
include: | ||
- stage: lint | ||
go: 1.12.x | ||
before_install: curl -sfL https://install.goreleaser.com/github.com/golangci/golangci-lint.sh | sh -s -- -b $(go env GOPATH)/bin latest | ||
script: golangci-lint run -v |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.