projects
/
platform
/
upstream
/
llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6c0ee17
)
clang-format: Give clang-format-diff.py a -v option.
author
Daniel Jasper
<djasper@google.com>
Fri, 14 Nov 2014 13:27:28 +0000
(13:27 +0000)
committer
Daniel Jasper
<djasper@google.com>
Fri, 14 Nov 2014 13:27:28 +0000
(13:27 +0000)
With it, it prints the file being formatted. Apparently people are
formatting thousands of files and some progress indication is helpful.
llvm-svn: 221990
clang/tools/clang-format/clang-format-diff.py
patch
|
blob
|
history
diff --git
a/clang/tools/clang-format/clang-format-diff.py
b/clang/tools/clang-format/clang-format-diff.py
index
b896ffc
..
247dace
100755
(executable)
--- a/
clang/tools/clang-format/clang-format-diff.py
+++ b/
clang/tools/clang-format/clang-format-diff.py
@@
-52,6
+52,8
@@
def main():
r'|protodevel)',
help='custom pattern selecting file paths to reformat '
'(case insensitive, overridden by -regex)')
+ parser.add_argument('-v', '--verbose', action='store_true',
+ help='be more verbose, ineffective without -i')
parser.add_argument(
'-style',
help=
@@
-89,6
+91,8
@@
def main():
# Reformat files containing changes in place.
for filename, lines in lines_by_file.iteritems():
+ if args.i and args.verbose:
+ print 'Formatting', filename
command = [binary, filename]
if args.i:
command.append('-i')