[script] add clang-tidy check and fix (#5675)

This commit is contained in:
Jonathan Hui
2020-10-22 10:36:59 -07:00
parent 3d189a10ce
commit 700ef9fe93
3 changed files with 127 additions and 26 deletions
+4 -2
View File
@@ -58,8 +58,10 @@ install_packages_apt()
echo 'Installing pretty tools useful for code contributions...'
# add clang-format for pretty
sudo apt-get --no-install-recommends install -y clang-format-10
# add clang-format and clang-tidy for pretty
sudo apt-get --no-install-recommends install -y clang-format-10 clang-tidy-10
sudo ln -sf /usr/bin/clang-tidy-10 /usr/bin/clang-tidy
sudo ln -sf /usr/bin/clang-apply-replacements-10 /usr/bin/clang-apply-replacements
# add yapf for pretty
python3 -m pip install yapf==0.29.0 || echo 'WARNING: could not install yapf, which is useful if you plan to contribute python code to the OpenThread project.'