mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-24 08:32:02 +00:00
Fix check-style util
This commit is contained in:
parent
102dad0ca0
commit
922add6244
@ -45,13 +45,12 @@ inc="-I. \
|
||||
-I./contrib/capnproto/c++/src \
|
||||
-I./contrib/unixodbc/include \
|
||||
-I./contrib/unixodbc-cmake/linux_x86_64 \
|
||||
-I./libs/libmysqlxx/include \
|
||||
-I./libs/libcommon/include \
|
||||
-I${BUILD_DIR}/libs/libcommon/include \
|
||||
-I./libs/libzkutil/include \
|
||||
-I./libs/libdaemon/include \
|
||||
-I./libs/consistent-hashing \
|
||||
-I./libs/consistent-hashing-sumbur \
|
||||
-I./base/mysqlxx \
|
||||
-I./base \
|
||||
-I${BUILD_DIR}/base \
|
||||
-I./base/daemon \
|
||||
-I./base/consistent-hashing \
|
||||
-I./base/consistent-hashing-sumbur \
|
||||
-I./contrib/libhdfs3/include \
|
||||
-I./contrib/base64/include \
|
||||
-I./contrib/protobuf/src \
|
||||
@ -65,7 +64,7 @@ inc="-I. \
|
||||
|
||||
if [ -z $1 ]; then
|
||||
cd ${ROOT_DIR=${CUR_DIR}../..}
|
||||
find dbms libs utils \( -name *.h -and -not -name *.inl.h \) -print0 | xargs -0 -n1 sh $CUR_DIR`basename $0`
|
||||
find base dbms utils \( -name *.h -and -not -name *.inl.h \) -print0 | xargs -0 -n1 sh $CUR_DIR`basename $0`
|
||||
else
|
||||
echo -n "$1 "
|
||||
echo -n `grep "#include" $1| wc -l` " "
|
||||
|
@ -6,7 +6,7 @@ cd `readlink -f $(dirname $0)`/../..
|
||||
|
||||
clang_format=`bash -c "compgen -c clang-format | grep 'clang-format-[[:digit:]]' | sort --version-sort --reverse | head -n1"`
|
||||
if [ ! -z $clang_format ]; then
|
||||
find dbms libs utils -name *.cpp -or -name *.h -exec $clang_format -i {} + ;
|
||||
find base dbms utils -name *.cpp -or -name *.h -exec $clang_format -i {} + ;
|
||||
else
|
||||
echo clang-format missing. try to install:
|
||||
echo sudo apt install clang-format
|
||||
|
Loading…
Reference in New Issue
Block a user