Skip to content

Instantly share code, notes, and snippets.

SpellCheck:
enabled: true
description: 'Check for misspelled words'
required_executable: 'hunspell'
flags: ['-a']
MessageFormat:
enabled: true
description: 'Check commit message matches expected pattern'
pattern: 'Close #(.+)[|](.+)'
expected_pattern_message: 'Close #<Issue Id> | <Description>'
sample_message: 'Close #BUG-1234 | Fix syntax bug'
on_warn: fail
@wshihadeh
wshihadeh / endTrailingPeriod.yaml
Created May 12, 2020 07:58
endTrailingPeriod
endTrailingPeriod:
enabled: true
description: 'Check for trailing periods in subject'
required: true
on_warn: fail
@wshihadeh
wshihadeh / CapitalizedSubject.yaml
Created May 12, 2020 07:56
CapitalizedSubject
CapitalizedSubject:
enabled: true
description: 'Check subject capitalization'
on_warn: fail
TextWidth:
enabled: true
description: 'Check text width'
max_subject_width: 60
min_subject_width: 4
max_body_width: 72
EmptyMessage:
enabled: true
description: 'Check for empty commit message'
BundleInstall:
enabled: true
description: 'Install Bundler dependencies'
requires_files: true
required_executable: 'bundle'
install_command: 'gem install bundler'
flags: ['install']
include:
- 'Gemfile'
- 'Gemfile.lock'
@wshihadeh
wshihadeh / multlinelog.rb
Created April 26, 2020 09:36
multlinelog
<filter multiline.**>
@type concat
key message
stream_identity_key request_id
multiline_start_regexp /^I, \[.+\] INFO -- : \[.+\] Started.+for.+at.+/
multiline_end_regexp /^I, \[.+\] INFO -- : \[.+\] Completed.+/
flush_interval 60
timeout_label @MULTILINE_LOGS
</filter>
@wshihadeh
wshihadeh / multlinelog.rb
Created April 26, 2020 09:36
multlinelog
<filter multiline.**>
@type concat
key message
stream_identity_key request_id
multiline_start_regexp /^I, \[.+\] INFO -- : \[.+\] Started.+for.+at.+/
multiline_end_regexp /^I, \[.+\] INFO -- : \[.+\] Completed.+/
flush_interval 60
timeout_label @MULTILINE_LOGS
</filter>
@wshihadeh
wshihadeh / multiline.con
Created April 26, 2020 09:35
multiline
<filter multiline.**>
@type concat
key message
multiline_start_regexp /^(E|F), \[[^ ]+ \#\d+\]( )+[^ ]+ -- :/
continuous_line_regexp /^(?!(^., \[[^ ]+ \#\d+\]( )+[^ ]+ -- :)).+/
flush_interval 60
timeout_label @MULTILINE_LOGS
</filter>