Bug 965120 - Use .clang-format to set tree default format; r=gps

This commit is contained in:
Anthony Jones 2014-01-30 14:27:44 +13:00
Родитель 147a7bcbdb
Коммит a4c0bcf9b0
3 изменённых файлов: 3 добавлений и 1 удалений

1
.clang-format Normal file
Просмотреть файл

@ -0,0 +1 @@
BasedOnStyle: Mozilla

Просмотреть файл

@ -1,2 +1,3 @@
\mfbt/
\js/
\media/

Просмотреть файл

@ -356,7 +356,7 @@ class FormatProvider(MachCommandBase):
from subprocess import Popen, PIPE
p1 = Popen(["hg", "diff", "-U0", "-r", "tip^", "--include", "glob:**.c", "--include", "glob:**.cpp",
"--include", "glob:**.h", "--exclude", "listfile:.clang-format-ignore"], stdout=PIPE)
args = [sys.executable, clang_format_diff, "-p1", "-style=Mozilla"]
args = [sys.executable, clang_format_diff, "-p1"]
if not show:
args.append("-i")
p2 = Popen(args, stdin=p1.stdout)