Skip to content

Commit

Permalink
Add details formatting to changelog
Browse files Browse the repository at this point in the history
  • Loading branch information
philnewm committed Nov 4, 2024
1 parent 165e754 commit 6c9ad3a
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/conversion_logic.py
Original file line number Diff line number Diff line change
Expand Up @@ -135,10 +135,14 @@ def format_changelog_markdown(changes: List[Changelog], changelog_label_list: Li
continue

formatted_label: str = label.removeprefix("type: ").capitalize()
changelog += f"\n## {formatted_label}\n\n"
changelog += f"\n### **{formatted_label}**\n\n"

for change in changes:
if label in change.labels:
changelog += f"* {change.title} - [{change.number}]({change.url})\n"
changelog += f"<details>\n"
changelog += f"<summary>{change.title} - [#{change.number}]({change.url})</summary>\n\n"
changelog += f"details\n\n\n"
changelog += f"___\n\n"
changelog += f"</details>"

return changelog

0 comments on commit 6c9ad3a

Please sign in to comment.