Documentation
¶
Index ¶
Constants ¶
const ( OutFormatText = "text" OutFormatSimple = "simple" OutFormatGitHubActions = "github-actions" OutFormatErrorformat = "efm" )
Variables ¶
var OutFormats = []string{ OutFormatText, OutFormatSimple, OutFormatGitHubActions, OutFormatErrorformat, }
var OutFormatsString = strings.Join(OutFormats, ",")
Functions ¶
This section is empty.
Types ¶
type ErrorFormat ¶ added in v0.1.10
type ErrorFormat struct {
// contains filtered or unexported fields
}
ErrorFormat is a ErrorFormat printer meant to be read by errorformat https://vim-jp.org/vimdoc-en/quickfix.html#error-file-format
func NewErrorFormat ¶ added in v0.1.10
func NewErrorFormat() *ErrorFormat
NewErrorFormat returns a new ErrorFormat printer
func (*ErrorFormat) Print ¶ added in v0.1.10
func (e *ErrorFormat) Print(fs *result.FileResults) error
Print prints in the format 'filename:line:column: [s] message' where `s` is the first character of Severity The formatting is meant to line up with errorformat "%f:%l:%c [%t] %m" https://vim-jp.org/vimdoc-en/quickfix.html#error-file-format
type GitHubActions ¶
type GitHubActions struct{}
GitHubActions is a GitHubActions printer meant for use by a GitHub Action annotation
func NewGitHubActions ¶
func NewGitHubActions() *GitHubActions
NewGitHubActions returns a new GitHubActions printer
func (*GitHubActions) Print ¶
func (p *GitHubActions) Print(fs *result.FileResults) error
Print prints in the format for GitHub actions https://docs.github.com/en/actions/reference/workflow-commands-for-github-actions#setting-an-error-message
type Printer ¶
type Printer interface {
Print(*result.FileResults) error
}
Printer is an interface for printing FileResults
func NewPrinter ¶ added in v0.1.1
type Simple ¶
type Simple struct {
// contains filtered or unexported fields
}
Simple is a simple printer meant for a machine to read
func (*Simple) Print ¶
func (s *Simple) Print(fs *result.FileResults) error
Print prints in the format 'filename:line:column: message' based on golint's output: https://github.com/golang/lint/blob/738671d3881b9731cc63024d5d88cf28db875626/golint/golint.go#L121