Sha256: b67be8d88691d966a93cb0fe0b8e4039a8d1f1502932287fb9ca4835e86f5791

Contents?: true

Size: 384 Bytes

Versions: 6

Compression:

Stored size: 384 Bytes

Contents

module Danger
  class DangerCommitLint < Plugin
    class SubjectLengthCheck < CommitCheck # :nodoc:
      MESSAGE = 'Please limit commit subject line to 50 characters.'.freeze

      def self.type
        :subject_length
      end

      def initialize(message)
        @subject = message[:subject]
      end

      def fail?
        @subject.length > 50
      end
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
danger-commit_lint-0.0.6 lib/commit_lint/subject_length_check.rb
danger-commit_lint-0.0.5 lib/commit_lint/subject_length_check.rb
danger-commit_lint-0.0.4 lib/commit_lint/subject_length_check.rb
danger-commit_lint-0.0.3 lib/commit_lint/subject_length_check.rb
danger-commit_lint-0.0.2 lib/commit_lint/subject_length_check.rb
danger-commit_lint-0.0.1 lib/commit_lint/subject_length_check.rb