Skip to content
This repository has been archived by the owner on Dec 7, 2020. It is now read-only.

Run golangci-lint as part of pull request workflow #604

Closed
abstractj opened this issue May 5, 2020 · 4 comments · Fixed by #607
Closed

Run golangci-lint as part of pull request workflow #604

abstractj opened this issue May 5, 2020 · 4 comments · Fixed by #607
Assignees

Comments

@abstractj
Copy link

abstractj commented May 5, 2020

What

Unfortunately GolangCI is closing and we need to migrate to another alternative. So we can have a sanity check for upcoming pull requests.

How

  • GolangCI service was closed, but the linter golangci-lint will be maintained, which means that we can benefit from this using GitHub actions.

Additional information

@abstractj abstractj added this to the 1.0.0 milestone May 5, 2020
@JoelSpeed
Copy link
Contributor

I've not used codeclimate before, but it seems like it suggests sensible improvements. I'd be intrigued to see what happens if you put up something that is considered bad form, will it comment on the PR?

I noticed it has also scanned master for issues, is there a way to mark those as false positives? Eg I noticed one is the config validation having too many returns, that would probably be an exception right?

@abstractj
Copy link
Author

abstractj commented May 6, 2020

Hi @JoelSpeed, yes it will add comments on the PR, but probably we might need to customize to our own needs to prevent false positives and some annoyance. You can have an idea of looking at these links:

Unfortunately, GolangCI will no longer available and these are the only alternatives I can think at the moment:

  1. Remove GolangCI and no longer have any feedback on pull requests. That's perfectly fine, as
    long as we introduce a process for people to check their code before submitting or merging it.
  2. Move to another CI that it does something similar, like Reviewdog

If you have any other ideas, please do not hesitate to comment here.

@abstractj abstractj removed this from the 1.0.0 milestone May 6, 2020
@abstractj
Copy link
Author

Btw I'm removing it from milestone 1.0.0, so we don't need to rush on the decision about this.

@abstractj abstractj changed the title Add Code Climate as part of pull request workflow Run golangci-lint as part of pull request workflow May 7, 2020
@abstractj abstractj self-assigned this May 7, 2020
@abstractj
Copy link
Author

@JoelSpeed updated the description and the content too. I believe this alternative makes more sense and it is something which we are already familiar.

abstractj pushed a commit to abstractj/louketo-proxy that referenced this issue May 7, 2020
abstractj pushed a commit to abstractj/louketo-proxy that referenced this issue May 8, 2020
abstractj pushed a commit to abstractj/louketo-proxy that referenced this issue May 8, 2020
abstractj pushed a commit to abstractj/louketo-proxy that referenced this issue May 8, 2020
abstractj pushed a commit to abstractj/louketo-proxy that referenced this issue May 14, 2020
- 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
abstractj pushed a commit to abstractj/louketo-proxy that referenced this issue May 14, 2020
- 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
abstractj pushed a commit to abstractj/louketo-proxy that referenced this issue May 14, 2020
- 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
abstractj pushed a commit that referenced this issue May 15, 2020
- 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 #604
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants