Merged in bugfix/create-changelog-when-missing (pull request #41)

bugfix: create changelog when missing

Approved-by: Jonathan Teran
This commit is contained in:
JonathanGitFlow
2025-12-04 13:13:14 +00:00
committed by jt
+1 -2
View File
@@ -16,8 +16,6 @@ class Changelog:
return f"""## {title} - {now.strftime("%F")} return f"""## {title} - {now.strftime("%F")}
### Commits
""" """
def generate_content(self, base: str, branch: str): def generate_content(self, base: str, branch: str):
@@ -56,5 +54,6 @@ class Changelog:
if isfile(self.FILENAME): if isfile(self.FILENAME):
with open(self.FILENAME, "r") as f: with open(self.FILENAME, "r") as f:
content += f.read() content += f.read()
with open(self.FILENAME, "w") as f: with open(self.FILENAME, "w") as f:
f.write(content) f.write(content)