-
Notifications
You must be signed in to change notification settings - Fork 345
Run golangci-lint as part of pull request workflow #604 #607
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there an easy way we can test these workflows before merging?
.github/workflows/go.yml
Outdated
if [ -f Gopkg.toml ]; then | ||
curl https://raw.githubusercontent.com/golang/dep/master/install.sh | sh | ||
dep ensure | ||
fi |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This repo uses go modules right? we can drop this
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @JoelSpeed updated. I just enabled it on GH and missed that part.
Yes, you can look at the fork here https://github.com/abstractj/louketo-proxy/actions. As you may notice, there are several alerts there for golangci-lint. Which ones do you think we should disable? IMO the alerts for |
In general I think the complexity ones are good, but you can get ones that are a bit annoying, such as the ones highlighted here. I believe we can add an exception to |
@JoelSpeed np, let's keep it. Found a typo on my YAML file, but it's fixed now. If there's anything else that you would like to change, please let me know. |
Do you think we should try and fixup the linting issues before merging this? Probably as a separate PR? |
@JoelSpeed of course, we can do that, there's no need to rush about merging this. |
- Merge build and linter jobs in a single file - Runs tests for go 1.13 and 1.14 - Introduces code coverage with coveralls - Fixes some issues reported by golangci-lint and relax/disable some rules until the codebase is refactored Resolves louketo#604
@stianst could you please review? |
Changes
rules until the codebase is refactored
Running example:
Testing this PR
build.yml
file from this PR and add it to.github/workflows
into the fork ofLouketo
master
at your forkRelates to #615
Resolves #604