conventionalcommits.org
conventionalcommits.org copied to clipboard
How do you do multi-line breaking changes?
I have this example.
BREAKING CHANGE: You no longer have to use alertTitle
and children
to display your alert content. Use children
only instead. This is because we found out that people actually display the "content" of the alert in alertTitle
and not in both alertTitle
and children
(description). Because of that, we're consolidating both. This also opens up opportunities to have other components used within an alert component like an accordion for Progressive Disclosure design patterns.
-<InlineCriticalAlert alertTitle='ALERT SUMMARY'/>
+<InlineCriticalAlert>
+ ALERT SUMMARY
+</InlineCriticalAlert>
I want the diff to also be added when creating release notes but it only adds whatever is added right after the BREAKING CHANGE:
keyword.
This very much depends on the parser you are using and not the spec itself, so you should likely file an issue on the parser/tool you are using.
I have a golang parser which I added this example as a test case to so that it will support
No Extra Line Breaks after the BREAKING CHANGE
https://gitlab.com/digitalxero/go-conventional-commit/-/blob/master/conventional_commits_test.go#L228
feat: add new feature
Description of the new feature
more details
even more details
BREAKING CHANGE: You no longer have to use alertTitle and children to display your alert content.
Use children only instead. This is because we found out that people actually display the "content" of the alert in alertTitle and not in both alertTitle and children (description).
Because of that, we're consolidating both. This also opens up opportunities to have other components used within an alert component like an accordion for Progressive Disclosure design patterns.
Extra Line Breaks after the BREAKING CHANGE
https://gitlab.com/digitalxero/go-conventional-commit/-/blob/master/conventional_commits_test.go#L258
feat: add new feature
Description of the new feature
more details
even more details
BREAKING CHANGE: You no longer have to use alertTitle and children to display your alert content.
Use children only instead. This is because we found out that people actually display the "content" of the alert in alertTitle and not in both alertTitle and children (description).
Because of that, we're consolidating both. This also opens up opportunities to have other components used within an alert component like an accordion for Progressive Disclosure design patterns.
The specification sounds more like BREAKING CHANGE
is a special footer:
If included as a footer, a breaking change MUST consist of the uppercase text BREAKING CHANGE, followed by a colon, space, and description, e.g., BREAKING CHANGE: environment variables now take precedence over config files.
So in that case it would behave the same as every other footer, newline + footer identifier to separate them.