cz-conventional-changelog icon indicating copy to clipboard operation
cz-conventional-changelog copied to clipboard

`answers. breakingBody` and `answers. issuesBody` does not affect the commit message at all.

Open Val-istar-Guo opened this issue 4 years ago • 2 comments

https://github.com/commitizen/cz-conventional-changelog/blob/e7bd5462966d00acb03aca394836b5427513681c/engine.js#L139-L154

answers.breakingBody does not affect the commit message at all.

https://github.com/commitizen/cz-conventional-changelog/blob/e7bd5462966d00acb03aca394836b5427513681c/engine.js#L207

I wrote breakingBody but found this doesn't make any sense. I read the code and I can't understand the meaning of this existence.

I find the issue https://github.com/commitizen/cz-conventional-changelog/issues/43 and https://github.com/commitizen/cz-conventional-changelog/pull/75.

Shouldn't the body be combined like this?

var b = answers.body || answers.breakingBody || answers.issuesBody
var body = b ? wrap(b , wrapOptions) : false; 

Val-istar-Guo avatar Mar 11 '20 09:03 Val-istar-Guo

+1 on this. I noticed this issue today. It affects both breakingBody and issuesBody.

As an example of what is happening:

At first, I skipped the body, but answered Yes for the Does this change affect any open issues? question, then it asked me to provide a longer description, but when I provided the description, it did not get added to the body section in the commit below the commit message.

Expected

feat(something): add some changes

These changes remove something and add a different thing

Closes XXXX

Actual

feat(something): add some changes

Closes XXXX

So, the issuesBody is not being used to construct the body at all.

s14k51 avatar Apr 15 '20 02:04 s14k51

#132 claims to fix this issue, and I would love to see this issue fixed. Is there anything I can do to help get things merged?

yarthur avatar Jun 17 '21 21:06 yarthur