(msg lint.Commit)
| 55 | func (r *FooterEmptyRule) Name() string { return "footer-empty" } |
| 56 | func (r *FooterEmptyRule) Apply(_ lint.RuleSetting) error { return nil } |
| 57 | func (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. |
| 65 | type DescriptionEmptyRule struct{} |