52 Star 246 Fork 3

腾讯开源 / ncnn

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
codeformat.sh 775 Bytes
一键复制 编辑 原始数据 按行查看 历史
nihui 提交于 2024-02-22 13:44 . ruapu cpu isa detection (#5341)
#!/usr/bin/env bash
# we run clang-format and astyle twice to get stable format output
format_code() {
find src/ tools/ tests/ examples/ benchmark/ python/ -type f -name '*.c' -o -name '*.cpp' -o -name '*.cc' -o -name '*.h' | grep -v python/pybind11 | grep -v stb_image | grep -v ruapu | xargs -i clang-format -i {}
astyle -n -r "benchmark/*.h,*.cpp,*.cc" "tests/*.h,*.cpp,*.cc" "tools/*.h,*.cpp,*.cc" "examples/*.h,*.cpp,*.cc"
astyle -n -r "src/*.h,*.cpp,*.cc" --exclude=src/stb_image.h --exclude=src/stb_image_write.h --exclude=src/ruapu.h
astyle -n -r "python/*.h,*.cpp,*.cc" --exclude=python/pybind11
}
format_code || { echo 'Formatting failed' ; exit 1; } #first time execute
format_code || { echo 'Formatting failed' ; exit 1; } #second time execute
C/C++
1
https://gitee.com/Tencent/ncnn.git
git@gitee.com:Tencent/ncnn.git
Tencent
ncnn
ncnn
master

搜索帮助