[glom] Add a manual reformat make target.



commit fb4377344b07b7c2153a455fda32daefa32509fa
Author: Murray Cumming <murrayc murrayc com>
Date:   Sat Feb 27 16:10:23 2016 +0100

    Add a manual reformat make target.

 .clang-format |   14 ++++++++++++++
 configure.ac  |    3 +++
 2 files changed, 17 insertions(+), 0 deletions(-)
---
diff --git a/.clang-format b/.clang-format
new file mode 100644
index 0000000..b1a077a
--- /dev/null
+++ b/.clang-format
@@ -0,0 +1,14 @@
+BasedOnStyle: Mozilla
+Standard: Cpp11
+AlignAfterOpenBracket: false
+AlignEscapedNewlinesLeft: true
+AlwaysBreakAfterDefinitionReturnType: None
+BreakBeforeBraces: Allman
+BreakConstructorInitializersBeforeComma: false
+ColumnLimit: 100
+ConstructorInitializerAllOnOneLineOrOnePerLine: true
+ConstructorInitializerIndentWidth: 0
+IndentCaseLabels: false
+SortIncludes: false
+AlignTrailingComments: false
+
diff --git a/configure.ac b/configure.ac
index 03929eb..c91ffb4 100644
--- a/configure.ac
+++ b/configure.ac
@@ -391,6 +391,9 @@ AC_MSG_RESULT($enable_gcov)
 GLIB_COMPILE_RESOURCES=`$PKG_CONFIG --variable glib_compile_resources gio-2.0`
 AC_SUBST(GLIB_COMPILE_RESOURCES)
 
+AC_CHECK_PROGS([CLANG_FORMAT], [clang-format clang-format-3.9 clang-format-3.8 clang-format-3.7], [])
+AM_CONDITIONAL([HAVE_CLANG_FORMAT], test -n "$CLANG_FORMAT")
+
 AC_CONFIG_FILES([Makefile
                  po/Makefile.in
                  glom.desktop.in


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]