commit-analyzer icon indicating copy to clipboard operation
commit-analyzer copied to clipboard

Why is this not using recommendedBumpOpts?

Open Ponjimon opened this issue 5 years ago • 6 comments

See https://github.com/favoloso/conventional-changelog-emoji/issues/20#issuecomment-606773923

I wanted to use semantic-release together with the linked package, but unfortunately, it's not working out of the box, I rather need to define all the release rules within the release config, but conventional-changelog actually offers a recommededBumpOpts method that determines if a release is neccessary or not.

Ponjimon avatar Mar 31 '20 18:03 Ponjimon

Can you clarify what you are asking exactly? You mention a recommededBumpOpts without providing a link or anything so I don't know what you are referring to.

pvdlg avatar Apr 07 '20 22:04 pvdlg

I did provide a link: https://github.com/favoloso/conventional-changelog-emoji/issues/20#issuecomment-606773923

Ponjimon avatar Apr 07 '20 22:04 Ponjimon

You provided a link to a plugin you are trying to use. And it seems a solution was provided in the issue you opened there.

You are asking here to solve you problem in a different way with a recommededBumpOpts method. But I have no idea what that method is or where it lives.

pvdlg avatar Apr 07 '20 22:04 pvdlg

It's basically how conventional-changelog determines if a version bump is required or not. It's a direct dependency of semantic-release/commit-analyzer:

https://github.com/semantic-release/commit-analyzer/blob/master/package.json#L31

And it's used here, for example: https://github.com/conventional-changelog/conventional-changelog/blob/0d7385543cbf14394206c2f739a82d1ccf118586/packages/conventional-changelog-conventionalcommits/index.js#L18

Ponjimon avatar Apr 07 '20 22:04 Ponjimon

I'm aware of this plugin using conventional-changelog as I wrote that code. I'm asking about recommededBumpOpts as I don't find any reference about this method you are talking about.

pvdlg avatar Apr 07 '20 23:04 pvdlg

@pvdlg Hello! I'm the plugin author mentioned before. recommendedBump is the way conventional-changelog detects which semver change should be applied in the next release, as used by its cli. You can find the package here: conventional-recommended-bump.

It seems to me there is already a way to find the recommended bump included in conventional-changelog, maybe semantic-release can use it too?

leonardfactory avatar Jun 03 '20 09:06 leonardfactory