Force -style=file for xb lint.

This commit is contained in:
gibbed 2020-02-22 13:23:54 -06:00 committed by Rick Gibbed
parent a6e6f0f7bf
commit de50780107
1 changed files with 2 additions and 0 deletions

View File

@ -1253,6 +1253,7 @@ class LintCommand(Command):
'third_party/clang-format/git-clang-format', 'third_party/clang-format/git-clang-format',
'--binary=%s' % (clang_format_binary), '--binary=%s' % (clang_format_binary),
'--commit=%s' % ('origin/master' if args['origin'] else 'HEAD'), '--commit=%s' % ('origin/master' if args['origin'] else 'HEAD'),
'--style=file',
'--diff', '--diff',
], throw_on_error=False, stdout_path=difftemp) ], throw_on_error=False, stdout_path=difftemp)
with open(difftemp) as f: with open(difftemp) as f:
@ -1269,6 +1270,7 @@ class LintCommand(Command):
'third_party/clang-format/git-clang-format', 'third_party/clang-format/git-clang-format',
'--binary=%s' % (clang_format_binary), '--binary=%s' % (clang_format_binary),
'--commit=%s' % ('origin/master' if args['origin'] else 'HEAD'), '--commit=%s' % ('origin/master' if args['origin'] else 'HEAD'),
'--style=file',
'--diff', '--diff',
]) ])
print('ERROR: 1+ diffs. Stage changes and run \'xb format\' to fix.') print('ERROR: 1+ diffs. Stage changes and run \'xb format\' to fix.')