Skip to content

Commit

Permalink
Merge pull request #18 from CircleCI-Public/dnephin/fix-gometalinter-…
Browse files Browse the repository at this point in the history
…in-ci

Fix gometalinter flakes by setting CGO_ENABLED=0
  • Loading branch information
marcomorain authored Jul 9, 2018
2 parents 95c941f + a90054a commit b4f9d52
Show file tree
Hide file tree
Showing 3 changed files with 38 additions and 2 deletions.
4 changes: 3 additions & 1 deletion .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,9 +30,11 @@ jobs:
docker:
- image: supinf/gometalinter:latest
working_directory: /go/src/github.com/CircleCI-Public/circleci-cli
environment:
CGO_ENABLED: 0
steps:
- checkout
- run: gometalinter --deadline 60s --exclude=/usr/local/go/ --exclude ^vendor ./...
- run: gometalinter ./...

deploy:
executor: go
Expand Down
34 changes: 34 additions & 0 deletions .gometalinter.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
{
"Vendor": true,
"Deadline": "5m",
"Concurrency": 2,
"Linters": {
"gofmt": {"Command": "gofmt -l -s -w"},
"goimports": {"Command": "goimports -l -w"}
},

"Enable": [
"deadcode",
"errcheck",
"gas",
"goconst",
"gocyclo",
"gofmt",
"goimports",
"golint",
"gosimple",
"gotype",
"gotypex",
"ineffassign",
"interfacer",
"megacheck",
"misspell",
"nakedret",
"structcheck",
"unconvert",
"unparam",
"varcheck",
"vet",
"vetshadow"
]
}
2 changes: 1 addition & 1 deletion cmd/root.go
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ func MakeCommands() *cobra.Command {
// https://github.com/spf13/cobra/issues/340
// If you expose a command with `RunE`, and return an error from your
// command, then Cobra will print the error message, followed by the usage
// infomation for the command. This makes it really difficult to see what's
// information for the command. This makes it really difficult to see what's
// gone wrong. It usually prints a one line error message followed by 15
// lines of usage information.
// This flag disables that behaviour, so that if a comment fails, it prints
Expand Down

0 comments on commit b4f9d52

Please sign in to comment.