提交 4cb7fa8e 编写于 作者: M Megvii Engine Team

ci(check): force check clang-format version

GitOrigin-RevId: 5080264f5fca298f9c33f3a6f95670c8ddecb6c8
上级 f7d05db7
......@@ -104,6 +104,21 @@ def main():
else:
raise ValueError("Invalid path {}".format(path))
# check version, we only support 12.0.1 now
version = subprocess.check_output(
[
args.clang_format,
"--version",
],
)
version = version.decode("utf-8")
need_version = '12.0.1'
if version.find(need_version) < 0:
print('We only support {} now, please install {} version, find version: {}'
.format(need_version, need_version, version))
raise RuntimeError('clang-format version not equal {}'.format(need_version))
process_map(
partial(process_file, clang_format=args.clang_format, write=args.write,),
files,
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册