added rubocop exceptions during guard runs

This commit is contained in:
Priit Tamboom 2014-10-09 13:52:28 +03:00
parent 6851e12c47
commit c1d840caa3
2 changed files with 12 additions and 1 deletions

10
.rubocop-guard.yml Normal file
View file

@ -0,0 +1,10 @@
inherit_from: .rubocop.yml
#
# Turn off during guard runs
#
# turn off comment intention check during development
# because NerdCommenter honors commented code intentions
Style/CommentIndentation:
Enabled: false

View file

@ -26,9 +26,10 @@ group :red_green_refactor, halt_on_fail:true do
# Martin does not want rubocop
unless Socket.gethostname == 'martin'
guard :rubocop do
guard :rubocop, cli: '--display-cop-names -c .rubocop-guard.yml' do
watch(%r{.+\.rb$})
watch(%r{(?:.+/)?\.rubocop\.yml$}) { |m| File.dirname(m[0]) }
watch(%r{(?:.+/)?\.rubocop-guard\.yml$}) { |m| File.dirname(m[0]) }
end
end
end