MCPcopy Index your code
hub / github.com/conventionalcommit/commitlint / Validate

Method Validate

rule/empty_rules.go:57–62  ·  view source on GitHub ↗
(msg lint.Commit)

Source from the content-addressed store, hash-verified

55func (r *FooterEmptyRule) Name() string { return "footer-empty" }
56func (r *FooterEmptyRule) Apply(_ lint.RuleSetting) error { return nil }
57func (r *FooterEmptyRule) Validate(msg lint.Commit) (*lint.Issue, bool) {
58 if msg.Footer() != "" {
59 return nil, true
60 }
61 return lint.NewIssue("footer must not be empty"), false
62}
63
64// DescriptionEmptyRule validates that the commit description is not empty.
65type DescriptionEmptyRule struct{}

Calls 2

NewIssueFunction · 0.92
FooterMethod · 0.65

Tested by 2