Skip to content

Commit 3b0bed0

Browse files
authored
Add clang format (#4)
* Add clang format Copied from apache arrow Signed-off-by: Junwang Zhao <[email protected]> * make clang-format language-specific Signed-off-by: Junwang Zhao <[email protected]> * use Regroup for IncludeBlocks and add IncludeCategories Signed-off-by: Junwang Zhao <[email protected]> --------- Signed-off-by: Junwang Zhao <[email protected]>
1 parent 7e97d8e commit 3b0bed0

File tree

1 file changed

+32
-0
lines changed

1 file changed

+32
-0
lines changed

.clang-format

Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
# Licensed to the Apache Software Foundation (ASF) under one
2+
# or more contributor license agreements. See the NOTICE file
3+
# distributed with this work for additional information
4+
# regarding copyright ownership. The ASF licenses this file
5+
# to you under the Apache License, Version 2.0 (the
6+
# "License"); you may not use this file except in compliance
7+
# with the License. You may obtain a copy of the License at
8+
#
9+
# http://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
# Unless required by applicable law or agreed to in writing,
12+
# software distributed under the License is distributed on an
13+
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14+
# KIND, either express or implied. See the License for the
15+
# specific language governing permissions and limitations
16+
# under the License.
17+
---
18+
Language: Cpp
19+
BasedOnStyle: Google
20+
ColumnLimit: 90
21+
DerivePointerAlignment: false
22+
IncludeBlocks: Regroup
23+
IncludeCategories:
24+
- Regex: '^<.*/' # Like <boost/lexical_cast.hpp>
25+
Priority: 3
26+
- Regex: '^<.*\.' # Like <fcntl.h>
27+
Priority: 1
28+
- Regex: '^<' # Like <vector>
29+
Priority: 2
30+
- Regex: '^"' # Like "util/auth-util.h"
31+
Priority: 4
32+
IndentPPDirectives: AfterHash

0 commit comments

Comments
 (0)