From cc63242c582ea7a4cb926149f8fd6f08d4869949 Mon Sep 17 00:00:00 2001
From: Florian Uhlig <f.uhlig@gsi.de>
Date: Tue, 9 Feb 2021 10:09:52 +0100
Subject: [PATCH] Add proper ordering of include statements

The include statements are ordered from local to global with allways a blank
line between the blocks.
---
 .clang-format | 17 ++++++++++++++++-
 1 file changed, 16 insertions(+), 1 deletion(-)

diff --git a/.clang-format b/.clang-format
index b9adbf5584..9564df548e 100644
--- a/.clang-format
+++ b/.clang-format
@@ -37,7 +37,22 @@ DerivePointerAlignment: false
 DisableFormat: false
 ExperimentalAutoDetectBinPacking: false
 FixNamespaceComments: true
-IncludeBlocks: Preserve
+IncludeBlocks: Regroup
+IncludeCategories:
+  - Regex:           '^("|<)Cbm'
+    Priority:        1
+  - Regex:           '^("|<)Fair'
+    Priority:        2
+  - Regex:           '^("|<)T'
+    Priority:        3
+  - Regex:           '^("|<)boost'
+    Priority:        4
+  - Regex:           '^<.*[^\.h]>'
+    Priority:        5
+  - Regex:           '^<.*>'
+    Priority:        6
+  - Regex:           '.*'
+    Priority:        7
 IndentCaseLabels: true
 IndentPPDirectives: None
 IndentWidth: 2
-- 
GitLab