Skip to content

Commit

Permalink
fix(scope): remove trailing whitespace in body
Browse files Browse the repository at this point in the history
  • Loading branch information
kmnhan committed Aug 15, 2024
1 parent ed3f6c3 commit e7383d9
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/cz_changeup/cz_changeup.py
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,9 @@ def changelog_message_builder_hook(

if self.show_body and commit.body:
msg += f"\n\n{' ' * self.body_indent}"
body = commit.body.replace("\n", "\n" + (" " * self.body_indent))
body = ("\n\n" + (" " * self.body_indent)).join(
[s.strip() for s in str(commit.body).split("\n") if s]
)
msg += f"{body}"

parsed_message["message"] = msg
Expand Down

0 comments on commit e7383d9

Please sign in to comment.