version='10' priority='80' for tool in 'clang' 'clang-tidy' 'clang-format' 'clangd' do sudo apt-get install "$tool-$version" sudo update-alternatives --install \ "/usr/bin/$tool" "$tool" "/usr/bin/$tool-$version" "$priority" done tool='clang-check' sudo apt-get install "clang-tools-$version" sudo update-alternatives --install \ "/usr/bin/$tool" "$tool" "/usr/bin/$tool-$version" "$priority"