chore: fix deprecatedComment issues from gocritic

Signed-off-by: Matthieu MOREL <matthieu.morel35@gmail.com>
pull/30867/head
Matthieu MOREL 6 months ago
parent 42f78ba60e
commit 83a0138172

@ -22,6 +22,7 @@ linters:
- depguard - depguard
- dupl - dupl
- exhaustive - exhaustive
- gocritic
- gomodguard - gomodguard
- govet - govet
- ineffassign - ineffassign
@ -66,6 +67,48 @@ linters:
exhaustive: exhaustive:
default-signifies-exhaustive: true default-signifies-exhaustive: true
gocritic:
disabled-checks:
- appendAssign
- appendCombine
- assignOp
- badCall
- commentedOutCode
- commentFormatting
- deferInLoop
- elseif
- emptyStringTest
- exposedSyncMutex
- filepathJoin
- httpNoBody
- hugeParam
- ifElseChain
- importShadow
- nestingReduce
- nilValReturn
- octalLiteral
- paramTypeCombine
- preferStringWriter
- ptrToRefParam
- rangeValCopy
- regexpSimplify
- singleCaseSwitch
- sloppyReassign
- sloppyLen
- sprintfQuotedString
- stringConcatSimplify
- stringsCompare
- stringXbytes
- todoCommentWithoutDetail
- tooManyResultsChecker
- typeAssertChain
- uncheckedInlineErr
- unnamedResult
- unnecessaryDefer
- unslice
- whyNoLint
enable-all: true
gomodguard: gomodguard:
blocked: blocked:
modules: modules:

@ -140,6 +140,7 @@ func (ch *Chart) AppVersion() string {
} }
// CRDs returns a list of File objects in the 'crds/' directory of a Helm chart. // CRDs returns a list of File objects in the 'crds/' directory of a Helm chart.
//
// Deprecated: use CRDObjects() // Deprecated: use CRDObjects()
func (ch *Chart) CRDs() []*common.File { func (ch *Chart) CRDs() []*common.File {
files := []*common.File{} files := []*common.File{}

@ -50,7 +50,8 @@ type MetadataLegacy struct {
PlatformCommand []PlatformCommand `yaml:"platformCommand"` PlatformCommand []PlatformCommand `yaml:"platformCommand"`
// Command is the plugin command, as a single string. // Command is the plugin command, as a single string.
// DEPRECATED: Use PlatformCommand instead. Removed in subprocess/v1 plugins. //
// Deprecated: Use PlatformCommand instead. Removed in subprocess/v1 plugins.
Command string `yaml:"command"` Command string `yaml:"command"`
// IgnoreFlags ignores any flags passed in from Helm // IgnoreFlags ignores any flags passed in from Helm
@ -60,7 +61,8 @@ type MetadataLegacy struct {
PlatformHooks PlatformHooks `yaml:"platformHooks"` PlatformHooks PlatformHooks `yaml:"platformHooks"`
// Hooks are commands that will run on plugin events, as a single string. // Hooks are commands that will run on plugin events, as a single string.
// DEPRECATED: Use PlatformHooks instead. Removed in subprocess/v1 plugins. //
// Deprecated: Use PlatformHooks instead. Removed in subprocess/v1 plugins.
Hooks Hooks `yaml:"hooks"` Hooks Hooks `yaml:"hooks"`
// Downloaders field is used if the plugin supply downloader mechanism // Downloaders field is used if the plugin supply downloader mechanism

@ -143,6 +143,7 @@ func (ch *Chart) AppVersion() string {
} }
// CRDs returns a list of File objects in the 'crds/' directory of a Helm chart. // CRDs returns a list of File objects in the 'crds/' directory of a Helm chart.
//
// Deprecated: use CRDObjects() // Deprecated: use CRDObjects()
func (ch *Chart) CRDs() []*common.File { func (ch *Chart) CRDs() []*common.File {
files := []*common.File{} files := []*common.File{}

Loading…
Cancel
Save