milvus/internal/core/run_clang_format.sh
xige-16 7a7a73e89c Fix high memory usage in pulsarTtStream
Signed-off-by: xige-16 <xi.ge@zilliz.com>
2021-02-23 11:40:12 +08:00

17 lines
439 B
Bash
Executable File

if [ -z $1 ]; then
echo "usage: $0 <path_to_core>"
exit -1
else
echo start formating
fi
CorePath=$1
formatThis() {
find "$1" | grep -E "(*\.cpp|*\.h|*\.cc)$" | grep -v "gen_tools/templates" | grep -v "/thirdparty" | grep -v "\.pb\." | xargs clang-format-10 -i
}
formatThis "${CorePath}/src"
formatThis "${CorePath}/unittest"
${CorePath}/build-support/add_license.sh ${CorePath}/build-support/cpp_license.txt ${CorePath}