Skip to content

Commit d7435dd

Browse files
committed
feat: add to the command for getting the release notes so that the header ends up being the new version
1 parent 3710aff commit d7435dd

File tree

1 file changed

+4
-2
lines changed
  • {{cookiecutter.project_name}}/scripts

1 file changed

+4
-2
lines changed

{{cookiecutter.project_name}}/scripts/util.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -120,9 +120,11 @@ def get_latest_release_notes() -> str:
120120
"The latest tag and version are the same. Please ensure the release notes are taken before tagging."
121121
)
122122
rev_range: str = "" if latest_tag is None else f"{latest_tag}..{latest_version}"
123-
123+
command: list[str] = [
124+
"uvx", "--from", "commitizen", "cz", "changelog", rev_range, "--dry-run", "--unreleased-version", latest_version
125+
]
124126
result: subprocess.CompletedProcess = subprocess.run(
125-
["uvx", "--from", "commitizen", "cz", "changelog", rev_range, "--dry-run"],
127+
command,
126128
cwd=REPO_FOLDER,
127129
capture_output=True,
128130
check=True

0 commit comments

Comments
 (0)