MCPcopy Index your code
hub / github.com/nodejs/node / main

Function main

tools/cpplint.py:8010–8031  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

8008
8009
8010def main():
8011 filenames = ParseArguments(sys.argv[1:])
8012 backup_err = sys.stderr
8013 try:
8014 # Change stderr to write with replacement characters so we don't die
8015 # if we try to print something containing non-ASCII characters.
8016 sys.stderr = codecs.StreamReader(sys.stderr, "replace")
8017
8018 _cpplint_state.ResetErrorCounts()
8019 for filename in filenames:
8020 ProcessFile(filename, _cpplint_state.verbose_level)
8021 # If --quiet is passed, suppress printing error count unless there are errors.
8022 if not _cpplint_state.quiet or _cpplint_state.error_count > 0:
8023 _cpplint_state.PrintErrorCounts()
8024
8025 if _cpplint_state.output_format == "junit":
8026 sys.stderr.write(_cpplint_state.FormatJUnitXML())
8027
8028 finally:
8029 sys.stderr = backup_err
8030
8031 sys.exit(_cpplint_state.error_count > 0)
8032
8033
8034if __name__ == "__main__":

Callers 1

cpplint.pyFile · 0.70

Calls 7

ResetErrorCountsMethod · 0.80
PrintErrorCountsMethod · 0.80
FormatJUnitXMLMethod · 0.80
ParseArgumentsFunction · 0.70
ProcessFileFunction · 0.70
writeMethod · 0.45
exitMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…