From 671b6b0893865e8f5fe32efee957035937498c00 Mon Sep 17 00:00:00 2001 From: notsatan Date: Thu, 19 Oct 2023 11:37:58 +0530 Subject: [PATCH] Fix: Remove deprecated linters Some linters were marked deprecated due to lack of active development upstream, removed them from the `.golangci.yml` configuration file Signed-off-by: notsatan --- .../.golangci.yml | 28 ++----------------- 1 file changed, 3 insertions(+), 25 deletions(-) diff --git a/{{ cookiecutter.project_name.strip() }}/.golangci.yml b/{{ cookiecutter.project_name.strip() }}/.golangci.yml index 4f4a27f..6b304df 100644 --- a/{{ cookiecutter.project_name.strip() }}/.golangci.yml +++ b/{{ cookiecutter.project_name.strip() }}/.golangci.yml @@ -285,26 +285,6 @@ linters-settings: # - shadow disable-all: false - depguard: - # linter to check if package imports are in a list of acceptable packages - list-type: blacklist # either `blacklist` or `whitelist` - include-go-root: false - # packages: - # - github.com/sirupsen/logrus - - # specify an error message to output when a blacklisted package is used - # packages-with-error-message: - # - github.com/sirupsen/logrus: "logging is allowed only by logutils.Log" - - ifshort: - # max length of variable declaration measured in number of lines, beyond which - # linter won't suggest using short syntax - higher priority than `max-decl-chars` - max-decl-lines: 1 - - # max length of variable declaration measured in number of characters, beyond which - # linter won't suggest using short syntax - max-decl-chars: 30 - lll: # max line length, lines longer will be reported. Default is 120. line-length: 88 # tab (`\t`) is counted as 1 character by default @@ -466,20 +446,16 @@ linters: disable-all: true # disable all, selectively enable what is needed enable: # Defaults - - deadcode - errcheck - gosimple - govet - ineffassign - staticcheck - - structcheck - typecheck - unused - - varcheck # Additional - cyclop - - depguard - dogsled - dupl - errname @@ -498,7 +474,6 @@ linters: - gomnd - goprintffuncname - gosec - - ifshort - lll - makezero - misspell @@ -536,3 +511,6 @@ linters: # version # - nilnil # - tenv + + # Might be useful for larger/coporate projects. Probably not for a hobby project + # - depguard