Sha256: 5823692e3c9ab9e12dd1a8100706767d62c789918b65d898622e12d81c45087d
Contents?: true
Size: 446 Bytes
Versions: 18
Compression:
Stored size: 446 Bytes
Contents
module Overcommit::GitHook class TextWidth < HookSpecificCheck include HookRegistry def run_check if commit_message.first.size > 60 return :warn, 'Please keep the subject < ~60 characters' end commit_message.each do |line| chomped = line.chomp if chomped.size > 72 return :warn, "> 72 characters, please hard wrap: '#{chomped}'" end end :good end end end
Version data entries
18 entries across 18 versions & 1 rubygems