Additional filename handling (#221)

This commit is contained in:
David Cameron
2023-06-20 06:09:28 -04:00
committed by GitHub
parent dc834e6ad2
commit 9b3db78b95
2 changed files with 58 additions and 0 deletions

View File

@@ -14,6 +14,12 @@ def parse_chat(chat): # -> List[Tuple[str, str]]:
# Remove leading and trailing brackets
path = re.sub(r"^\[(.*)\]$", r"\1", path)
# Remove leading and trailing backticks
path = re.sub(r"^`(.*)`$", r"\1", path)
# Remove trailing ]
path = re.sub(r"\]$", "", path)
# Get the code
code = match.group(2)