chore: 修复 Changelog 生成器生成的 merge commit 的作者与 message 中多空格的问题

This commit is contained in:
zzyyyl
2023-03-09 22:23:02 +08:00
parent 83e30d3b00
commit 2ee40f5c35

View File

@@ -127,7 +127,7 @@ def print_commits(commits: dict, indent: str = "", need_sort: bool = True) -> (s
print(f"Warning: `{x}` has no contributor!")
else:
contributor = contributor_re.group()
commit_message = re.sub(r"@\S*", "", commit_message)
commit_message = re.sub(r" *@\S*", "", commit_message)
mes, ctrs = print_commits(commits[x], indent + " ", False)
ret_message += indent + "- " + commit_message