未验证 提交 899efc4c 编写于 作者: S Sing_chan 提交者: GitHub

optimize installation and instruction of clang-format (#43248)

上级 33949fc5
...@@ -5,7 +5,15 @@ readonly VERSION="13.0.0" ...@@ -5,7 +5,15 @@ readonly VERSION="13.0.0"
version=$(clang-format -version) version=$(clang-format -version)
if ! [[ $(python -V 2>&1 | awk '{print $2}' | awk -F '.' '{print $1$2}') -ge 36 ]]; then
echo "clang-format installation by pip need python version great equal 3.6,
please change the default python to higher version."
exit 1
fi
if ! [[ $version == *"$VERSION"* ]]; then if ! [[ $version == *"$VERSION"* ]]; then
# low version of pip may not have the source of clang-format whl
pip install --upgrade pip
pip install clang-format==13.0.0 pip install clang-format==13.0.0
fi fi
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册