Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 4 additions & 1 deletion .github/scripts/run_cpp_linter.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import os
import json
import re

from github import Github
import subprocess
Expand All @@ -25,8 +26,10 @@
comment = """Code conforms to C++ style guidelines"""
approval = "APPROVE"
if output.returncode != 0:
lint_output = output.stdout.decode("utf-8")
lint_output = re.sub(r"[\x00-\x08\x0b\x0c\x0e-\x1f\x7f]", "", lint_output)
comment = """There are some changes that do not conform to C++ style guidelines:\n ```diff\n{}```""".format(
output.stdout.decode("utf-8")
lint_output
)
approval = "REQUEST_CHANGES"

Expand Down
Loading