clang-format: configuration for the clang-format source formatter
authorAugie Fackler <raf@durin42.com>
Sat, 24 Jan 2015 17:04:25 -0500
changeset 40343 e33381d95930b269df665f035c3d431705fcb6da
parent 40342 284fa44f7f39309f211457a7d130dbcb327ec80f
child 40344 0b46352384a094aa396cdfb38eec13e381437c3c
push id573
push usergszorc@mozilla.com
push dateWed, 18 Oct 2017 21:03:35 +0000
clang-format: configuration for the clang-format source formatter Differential Revision: https://phab.mercurial-scm.org/D1129
.clang-format
tests/test-check-code.t
new file mode 100644
--- /dev/null
+++ b/.clang-format
@@ -0,0 +1,8 @@
+BasedOnStyle: LLVM
+IndentWidth: 8
+UseTab: ForIndentation
+BreakBeforeBraces: Linux
+AllowShortIfStatementsOnASingleLine: false
+IndentCaseLabels: false
+AllowShortBlocksOnASingleLine: false
+AllowShortFunctionsOnASingleLine: false
--- a/tests/test-check-code.t
+++ b/tests/test-check-code.t
@@ -34,16 +34,17 @@ New errors are not allowed. Warnings are
   ...         print('commands in debugcommands.py not sorted; first differing '
   ...               'command is %s; expected %s' % (commands[i], command))
   ...         break
 
 Prevent adding new files in the root directory accidentally.
 
   $ testrepohg files 'glob:*'
   .arcconfig
+  .clang-format
   .editorconfig
   .hgignore
   .hgsigs
   .hgtags
   CONTRIBUTING
   CONTRIBUTORS
   COPYING
   Makefile