File tree 1 file changed +0
-4
lines changed
lib/overcommit/hook/pre_commit
1 file changed +0
-4
lines changed Original file line number Diff line number Diff line change @@ -2,13 +2,11 @@ module Overcommit::Hook::PreCommit
2
2
# Runs `rubocop` against any modified Ruby files.
3
3
class Rubocop < Base
4
4
def run
5
- puts "IN_PATH? #{ in_path? ( 'rubocop' ) } "
6
5
unless in_path? ( 'rubocop' )
7
6
return :warn , 'Rubocop not installed -- run `gem install rubocop`'
8
7
end
9
8
10
9
result = command ( "rubocop --format=emacs #{ applicable_files . join ( ' ' ) } 2>&1" )
11
- puts "RESULT: #{ result . success? } "
12
10
return :good if result . success?
13
11
14
12
# Keep lines from the output for files that we actually modified
@@ -20,8 +18,6 @@ def run
20
18
modified_lines ( file ) . include? ( line . to_i )
21
19
end
22
20
23
- puts "ERRORS: #{ error_lines . join ( "\n " ) } "
24
-
25
21
return :bad , error_lines . join ( "\n " ) unless error_lines . empty?
26
22
return :warn , "Modified files have lints (on lines you didn't modify)\n " <<
27
23
warning_lines . join ( "\n " )
You can’t perform that action at this time.
0 commit comments