[ci] Fix release branch matching

This commit is contained in:
Andrei Kvapil
2025-04-11 08:55:11 +02:00
parent 799690dc07
commit 12bedef2d3

View File

@@ -51,10 +51,10 @@ jobs:
with:
script: |
const branch = context.payload.pull_request.head.ref;
const match = branch.match(/^release-(v\d+\.\d+\.\d+(?:[-\w\.]+)?)$/);
const match = branch.match(/^release-(\d+\.\d+\.\d+(?:[-\w\.]+)?)$/);
if (!match) {
core.setFailed(`Branch '${branch}' does not match expected format 'release-vX.Y.Z[-suffix]'`);
core.setFailed(`Branch '${branch}' does not match expected format 'release-X.Y.Z[-suffix]'`);
} else {
const tag = match[1];
core.setOutput('tag', tag);