We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6d19bcf commit 8fcccf1Copy full SHA for 8fcccf1
scripts/ci/check_compliance.py
@@ -11,6 +11,7 @@
11
import logging
12
import os
13
from pathlib import Path
14
+import platform
15
import re
16
import subprocess
17
import sys
@@ -273,6 +274,8 @@ class ClangFormatCheck(ComplianceTest):
273
274
path_hint = "<git-top>"
275
276
def run(self):
277
+ exe = f"clang-format-diff.{'exe' if platform.system() == 'Windows' else 'py'}"
278
+
279
for file in get_files():
280
if Path(file).suffix not in ['.c', '.h']:
281
continue
@@ -281,7 +284,7 @@ def run(self):
284
stdout=subprocess.PIPE,
282
285
cwd=GIT_TOP)
283
286
try:
- subprocess.run(('clang-format-diff.py', '-p1'),
287
+ subprocess.run((exe, '-p1'),
288
check=True,
289
stdin=diff.stdout,
290
0 commit comments