代码拉取完成,页面将自动刷新
#!/bin/sh
set -e
LOCALSTRING="local"
if [ "$3" = "$LOCALSTRING" ]; then
REGEX="/cuberite/src/\.?[^\.]"
else
REGEX="cuberite_[^/\.]+/src/\.?[^\.]"
fi
FIXES_FILE="tidy-fixes.yaml"
ARGS="-header-filter $REGEX -quiet -export-fixes $FIXES_FILE $* $REGEX"
# Generate the compilation database
mkdir -p tidy-build
cd tidy-build
# Disable precompiled headers since they aren't generated during linting which causes an error
# Disable unity builds since clang-tidy needs the full list of compiled files to check each one
cmake --target Cuberite -DCMAKE_EXPORT_COMPILE_COMMANDS=Yes -DPRECOMPILE_HEADERS=No -DUNITY_BUILDS=No ..
# Ensure LuaState_Typedefs.inc has been generated
(cd ../src/Bindings && lua BindingsProcessor.lua)
if run-clang-tidy $ARGS; then
echo "clang-tidy: No violations found"
else
echo "clang-tidy: Found violations"
exit 1
fi
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。