Update code format (#24000)

revert-22778-infer_var_type
tianshuo78520a 5 years ago committed by GitHub
parent 6f5669f9bf
commit 109ffffbb2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -279,12 +279,18 @@ function check_style() {
pre-commit install
clang-format --version
commit_files=on
for file_name in `git diff --numstat upstream/$BRANCH |awk '{print $NF}'`;do
if ! pre-commit run --files $file_name ; then
git diff
exit 1
commit_files=off
fi
done
if [ $commit_files == 'off' ];then
echo "code format error"
exit 1
fi
trap : 0
}

Loading…
Cancel
Save