diff --git a/pkg/config/loader.go b/pkg/config/loader.go index a48381474c87..3dfe1cfd4d5f 100644 --- a/pkg/config/loader.go +++ b/pkg/config/loader.go @@ -350,6 +350,13 @@ func (l *Loader) handleDeprecation() error { l.cfg.Output.Formats = f } + for _, format := range l.cfg.Output.Formats { + if format.Format == OutFormatGithubActions { + l.log.Warnf("The output format `%s` is deprecated, please use `%s`", OutFormatGithubActions, OutFormatColoredLineNumber) + break // To avoid repeating the message if there are several usages of github-actions format. + } + } + l.handleLinterOptionDeprecations() return nil diff --git a/pkg/config/output.go b/pkg/config/output.go index 19d306949089..592e293e0b06 100644 --- a/pkg/config/output.go +++ b/pkg/config/output.go @@ -17,7 +17,7 @@ const ( OutFormatCodeClimate = "code-climate" OutFormatHTML = "html" OutFormatJunitXML = "junit-xml" - OutFormatGithubActions = "github-actions" + OutFormatGithubActions = "github-actions" // Deprecated OutFormatTeamCity = "teamcity" OutFormatSarif = "sarif" ) diff --git a/pkg/printers/githubaction.go b/pkg/printers/githubaction.go index 0d71b1c9b338..a37c4aeb67a4 100644 --- a/pkg/printers/githubaction.go +++ b/pkg/printers/githubaction.go @@ -15,6 +15,7 @@ type GitHubAction struct { } // NewGitHubAction output format outputs issues according to GitHub actions. +// Deprecated func NewGitHubAction(w io.Writer) *GitHubAction { return &GitHubAction{w: w} }