Sha256: 8d5d79dcc1a2298e8769ae12d2ebcbddd5c22e8b7386ccf72c86caa9be7aae9d
Contents?: true
Size: 822 Bytes
Versions: 9
Compression:
Stored size: 822 Bytes
Contents
# frozen_string_literal: true module Git module Lint module Analyzers # Analyzes commit trailer issue value. class CommitTrailerIssueValue < Abstract include Import[setting: "trailers.issue"] def valid? = affected_commit_trailers.empty? def issue return {} if valid? { hint: "Use format: #{filter_list.to_usage}.", lines: affected_commit_trailers } end protected def load_filter_list Kit::FilterList.new settings.commits_trailer_issue_value_includes end def invalid_line? trailer trailer.key.match?(setting.pattern) && !trailer.value.match?(value_pattern) end def value_pattern = /\A#{Regexp.union filter_list}\Z/ end end end end
Version data entries
9 entries across 9 versions & 1 rubygems