Skip to content

getNextVersion seems to have no effect #335

Open
@JammingBen

Description

@JammingBen

I'm currently setting getNextVersion to something I want my next version to be, but the Release-PR being created still has an auto generated version based on the latest version.

I'm guessing this is happening due to the following lines: https://github.com/woodpecker-ci/plugin-ready-release-go/blob/main/src/index.ts#L156. Shouldn't it also include a check if the user wants to overwrite the version via getNextVersion? Like this:

if (!isReleaseCommit && !nextVersion) {
  nextVersion = getNextVersionFromLabels(latestVersion, config.user, changes, shouldBeRC);
}

So it respects the user config getNextVersion? Or am I misunderstanding that config?

What I'm basically trying to achieve: Let's say I am on version 3.0.0 on my main branch and on version 2.1.0 on a stable branch that I'm still updating with patches. Now I want the plugin to create a 2.1.1 release from the stable branch. I thought I can achieve this via the getNextVersion config. But the next version in this example is always 3.0.1.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions