From 2c7bade63baecf9e7fd20c483903df22d6629541 Mon Sep 17 00:00:00 2001 From: Liam Stanley Date: Mon, 11 Sep 2023 12:48:22 -0400 Subject: [PATCH] chore(terraform): auto-applied ".golangci.yml" this file was auto-applied from the "github-common-files" module located here: - https://github.com/lrstanley/.github/tree/master/terraform/github-common-files instructions on how to tell Terraform to exclude this file: - https://github.com/lrstanley/.github/blob/master/example.ci-config.yml Signed-off-by: Liam Stanley --- .golangci.yml | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/.golangci.yml b/.golangci.yml index 1b4e722..9def06b 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -62,7 +62,6 @@ linters: - godot # checks if comments end in a period - godox # detects FIXME, TODO and other comment keywords - goimports # in addition to fixing imports, goimports also formats your code in the same style as gofmt - - gomnd # detects magic numbers - gomoddirectives # manages the use of 'replace', 'retract', and 'excludes' directives in go.mod - gomodguard # allow and block lists linter for direct Go module dependencies. This is different from depguard where there are different block types for example version constraints and module recommendations - goprintffuncname # checks that printf-like functions are named with f at the end @@ -99,6 +98,7 @@ linters: - whitespace # detects leading and trailing whitespace # disabled for now: + # - gomnd # detects magic numbers # - errname # checks that sentinel errors are prefixed with the Err and error types are suffixed with the Error # - gochecknoglobals # checks that no global variables exist # - gocognit # computes and checks the cognitive complexity of functions @@ -150,19 +150,19 @@ linters-settings: # Whether to skip (*x).method() calls where x is a pointer receiver. skipRecvDeref: false - gomnd: - # Values always ignored: `time.Date`, - # `strconv.FormatInt`, `strconv.FormatUint`, `strconv.FormatFloat`, - # `strconv.ParseInt`, `strconv.ParseUint`, `strconv.ParseFloat`. - ignored-functions: - - os.Chmod - - os.Mkdir - - os.MkdirAll - - os.OpenFile - - os.WriteFile - - prometheus.ExponentialBuckets - - prometheus.ExponentialBucketsRange - - prometheus.LinearBuckets + # gomnd: + # # Values always ignored: `time.Date`, + # # `strconv.FormatInt`, `strconv.FormatUint`, `strconv.FormatFloat`, + # # `strconv.ParseInt`, `strconv.ParseUint`, `strconv.ParseFloat`. + # ignored-functions: + # - os.Chmod + # - os.Mkdir + # - os.MkdirAll + # - os.OpenFile + # - os.WriteFile + # - prometheus.ExponentialBuckets + # - prometheus.ExponentialBucketsRange + # - prometheus.LinearBuckets gomodguard: blocked: