Skip to content

Commit

Permalink
Revert "Try fix: 在 commit"
Browse files Browse the repository at this point in the history
This reverts commit 0974c6b.
  • Loading branch information
SuperScript-PRC committed Nov 29, 2024
1 parent 0974c6b commit 0529ebf
Showing 1 changed file with 4 additions and 23 deletions.
27 changes: 4 additions & 23 deletions .github/release_produce.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,21 +31,7 @@ def generate_changelog(repo, max_version, version_file="version"):
)

new_commits_list = new_commits_log.split("\n")
new_real_commits_list = []
for item in new_commits_list:
if item:
try:
item = json.loads(item)
item.update({"avali": True})
except json.JSONDecodeError:
item = {
"commit": "Error",
"author": "Error",
"summary": item,
"date": "Error",
"avali": False
}

new_real_commits_list = [json.loads(item) for item in new_commits_list if item]

ToolDeltaVersion = open(version_file).read().strip()

Expand All @@ -60,14 +46,9 @@ def generate_changelog(repo, max_version, version_file="version"):
date = commit["date"]
if "github-actions" in summary or "GitHub" in summary:
continue
if commit["avali"]:
CHANGELOG.write(
f"- [[`{commit_id[:7]}`](https://github.com/ToolDelta/ToolDelta/commit/{commit_id})] {summary} By {author} ({date})\n"
)
else:
CHANGELOG.write(
f"- [`{commit_id[:7]}`] {summary}\n"
)
CHANGELOG.write(
f"- [[`{commit_id[:7]}`](https://github.com/ToolDelta/ToolDelta/commit/{commit_id})] {summary} By {author} ({date})\n"
)

def main():
repo_path = "/home/runner/work/Test"
Expand Down

0 comments on commit 0529ebf

Please sign in to comment.