Skip to content

Commit

Permalink
new configloader package
Browse files Browse the repository at this point in the history
Signed-off-by: Jorge Niedbalski <[email protected]>
  • Loading branch information
niedbalski committed Aug 30, 2023
1 parent c208b2c commit 4ff1aef
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
8 changes: 6 additions & 2 deletions .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,19 +5,24 @@ run:
# vendor$, third_party$, testdata$, examples$, Godeps$, builtin$
skip-dirs-use-default: true
linters-settings:
funlen:
lines: 100
statements: 50
goimports:
local-prefixes: github.com/calyptia/cloud
revive:
min-confidence: 0.8
gocyclo:
min-complexity: 15
min-complexity: 25
govet:
check-shadowing: true
misspell:
locale: US
gomnd:
ignored-numbers:
- 2 #used for word splitting.
gocognit:
min-complexity: 54
nolintlint:
allow-leading-space: false # require machine-readable nolint directives (with no leading space)
allow-unused: false # report any unused nolint directives
Expand All @@ -40,7 +45,6 @@ linters:
- unused
- varcheck
- bodyclose
- depguard
- dupl
- exportloopref
- forcetypeassert
Expand Down
1 change: 1 addition & 0 deletions configloader/loader.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ type RealFileReader struct{}

// ReadFile reads the content of the given filename.
func (r RealFileReader) ReadFile(filename string) ([]byte, error) {
//nolint:gosec //required filesystem access to read fixture data.
return os.ReadFile(filename)
}

Expand Down

0 comments on commit 4ff1aef

Please sign in to comment.