meshkit icon indicating copy to clipboard operation
meshkit copied to clipboard

Update golangci config

Open chung-coder opened this issue 9 months ago • 2 comments

Description

This PR fixes #693

Notes for Reviewers This PR updates golangci.yml by replacing deprecated linters and refining linting configurations for better code quality.

Before:

  • Running golangci-lint config verify resulted in errors due to incorrect or incompatible configuration.
  • Linters like golint and scopelint were used, but they were deprecated and caused validation issues.
  • The configuration had overlapping or conflicting settings for certain linters.

After:

  • Replaced deprecated linters:

    • golintrevive for better configurability and active maintenance.
    • scopelintcopyloopvar to improve variable scope analysis.
  • Updated golangci.yml settings:

    • Corrected and simplified the configuration for revive, govet, unused, and cyclop.
    • Explicitly set rules for revive to enforce line-length-limit: 120.
    • Removed unnecessary settings and streamlined the linter configurations to avoid conflicts.
  • Fixed validation issues:

    • Configured exclude-rules to exclude _test.go files from testpackage linter, preventing unnecessary checks for test files.
    • Adjusted the cyclop complexity limit to 7 for improved analysis.

Signed commits

  • [x] Yes, I signed my commits.

chung-coder avatar Mar 07 '25 00:03 chung-coder

Yay, your first pull request! :thumbsup: A contributor will be by to give feedback soon. In the meantime, you can find updates in the #github-notifications channel in the community Slack. Be sure to double-check that you have signed your commits. Here are instructions for making signing an implicit activity while performing a commit.

welcome[bot] avatar Mar 07 '25 00:03 welcome[bot]

Thank you, @chung-coder!

Will you:

  1. Review our approach to golanglint-ci in the https://github.com/meshery/meshery repo? We'll want to ensure a consistent approach, making changes here, there, or both places.
  2. Will you sign your commit? One-time instructions here. Permanent instructions here.

leecalcote avatar Mar 07 '25 17:03 leecalcote

No response from @chung-coder

hortison avatar Apr 21 '25 12:04 hortison

Marking PR as abandoned...

hortison avatar Apr 21 '25 12:04 hortison

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

stale[bot] avatar Jun 06 '25 02:06 stale[bot]

This issue is being automatically closed due to inactivity. However, you may choose to reopen this issue.

stale[bot] avatar Jun 16 '25 17:06 stale[bot]