Presubmit output to distinguish check phases.
Review URL: http://codereview.chromium.org/7795050 git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@9179 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
This commit is contained in:
parent
f131cce3fe
commit
6336eb7c20
@ -311,13 +311,17 @@ class SourceProcessor(SourceFileProcessor):
|
|||||||
|
|
||||||
def ProcessFiles(self, files, path):
|
def ProcessFiles(self, files, path):
|
||||||
success = True
|
success = True
|
||||||
|
violations = 0
|
||||||
for file in files:
|
for file in files:
|
||||||
try:
|
try:
|
||||||
handle = open(file)
|
handle = open(file)
|
||||||
contents = handle.read()
|
contents = handle.read()
|
||||||
success = self.ProcessContents(file, contents) and success
|
if not self.ProcessContents(file, contents):
|
||||||
|
success = False
|
||||||
|
violations += 1
|
||||||
finally:
|
finally:
|
||||||
handle.close()
|
handle.close()
|
||||||
|
print "Total violating files: %s" % violations
|
||||||
return success
|
return success
|
||||||
|
|
||||||
|
|
||||||
@ -333,8 +337,10 @@ def Main():
|
|||||||
parser = GetOptions()
|
parser = GetOptions()
|
||||||
(options, args) = parser.parse_args()
|
(options, args) = parser.parse_args()
|
||||||
success = True
|
success = True
|
||||||
|
print "Running C++ lint check..."
|
||||||
if not options.no_lint:
|
if not options.no_lint:
|
||||||
success = CppLintProcessor().Run(workspace) and success
|
success = CppLintProcessor().Run(workspace) and success
|
||||||
|
print "Running copyright header and trailing whitespaces check..."
|
||||||
success = SourceProcessor().Run(workspace) and success
|
success = SourceProcessor().Run(workspace) and success
|
||||||
if success:
|
if success:
|
||||||
return 0
|
return 0
|
||||||
|
Loading…
Reference in New Issue
Block a user