Closed
Description
Description
Removing the tag_format
config from the pyproject.toml
results in commitizen not being able to read the changelog for specific tags (it always prints the whole changelog). If tag_format
is a required parameter it should be noted in the documentation. Otherwise tag_format
should default to $version
, since this is how it is initialized.
This can cause a lot of confusion for existing projects that are introducing commitizen in their workflows without using cz init
and didn't add tag_format
explicitly in the pyproject.toml
.
Steps to reproduce
Give the following example setup
git init
cz init
git add . && git commit -m "feat: add pyproject"
cz bump
touch file1 && git add file1 && git commit -m "feat: add file1"
cz bump
Now check the changelog of the latest version
cz ch 0.2.0
cat CHANGELOG.md
## 0.2.0 (2022-11-27)
### Feat
- add file1
Remove tag_format
line from pyproject.toml
Check again
Current behavior
cz ch 0.2.0
cat CHANGELOG.md
## 0.2.0 (2022-11-27)
### Feat
- add file1
## 0.1.0 (2022-11-27)
### Feat
- add pyproject
Desired behavior
cz ch 0.2.0
cat CHANGELOG.md
## 0.2.0 (2022-11-27)
### Feat
- add file1
Screenshots
No response
Environment
cz version: 2.37.0
python version: 3.10.8