mattermost-community / mattermost-plugin-solar-lottery

A tool somewhat similar to pager duty, allows to have rotations with magic "solar lottery" scheduling, or overrides.
Apache License 2.0
4 stars 10 forks source link

Integrate GolangCI-Lint #39

Closed hanzei closed 4 years ago

hanzei commented 4 years ago

Mattermost is currently in the process of using golangci-lint as the default linter for all go projects. https://github.com/mattermost/mattermost-plugin-autolink/pull/108 serves as an example of how the migration should look like:

  1. Copy .golangci.yml from https://github.com/mattermost/mattermost-plugin-autolink/ into this repository.
  2. Copy Makefile from https://github.com/mattermost/mattermost-plugin-autolink/ into this repository.
  3. Copy build/ from https://github.com/mattermost/mattermost-plugin-autolink/ into this repository.
  4. Run go mod tidy and make dist to ensure the build system works fine.
  5. Update linters-settings.goimports.local-prefixes to the go module path i.e. to github.com/mattermost/mattermost-plugin-aws-SNS.
  6. Run make golangci-lint and fix all issues that arise.

Fixing an linter issue is sometimes trivial but can also be quite complicated. There might be cases, where ignoring an issue using issues.exclude-rules is needed. If you don't know how to resolve an error, please reach out to @hanzei on the Mattermost Community Server or ask the question here.

AugustasV commented 4 years ago

I would like to work on this issue!

hanzei commented 4 years ago

Thanks @AugustasV :+1: