Skip to content

Conversation

@Diaphteiros
Copy link
Contributor

What this PR does / why we need it:
During a release of the openmcp-operator, the lines

replace (
	github.com/openmcp-project/openmcp-operator/api => ./api
	github.com/openmcp-project/openmcp-operator/lib => ./lib
)

got replaced with

replace (
	github.com/openmcp-project/openmcp-operator/api <new_version>
	github.com/openmcp-project/openmcp-operator/lib <new_version>
)

This was due to a wrong regex, which was not expected to match these lines.

The problem didn't occur in the past and also not in other projects, because there we always have only a single replace statement, not a block, and the line needs to start with whitespace to be matched.

I added a v in the regex, so that it will now only match lines that have a version after the module path.

Which issue(s) this PR fixes:
None

Special notes for your reviewer:

Release note:

The `release:set-version` task had a bug that caused it to replace some lines in the `go.mod` file that it wasn't supposed to replace. This is now fixed.

@Diaphteiros Diaphteiros merged commit 3dc4c78 into main Sep 5, 2025
3 checks passed
@Diaphteiros Diaphteiros deleted the fix-set-version branch September 5, 2025 13:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants