From 366f3d3d30db67eaa0dd037e9721419ca40f5e84 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Nikola=20Forr=C3=B3?= Date: Tue, 14 Nov 2023 13:00:19 +0100 Subject: [PATCH] Make pre-release delimiter optional in do-release action MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Nikola Forró --- .github/workflows/do-release.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/do-release.yml b/.github/workflows/do-release.yml index 257598a..b30d61f 100644 --- a/.github/workflows/do-release.yml +++ b/.github/workflows/do-release.yml @@ -14,7 +14,7 @@ jobs: - uses: actions/checkout@v3 - name: Create GitHub release run: | - VERSION=$(grep -oP '^# \K[0-9.]+([.\-_][a-zA-Z0-9.\-_]+)?' CHANGELOG.md | head -n 1) + VERSION=$(grep -oP '^# \K[0-9.]+([.\-_]?[a-zA-Z0-9.\-_]+)?' CHANGELOG.md | head -n 1) # Take the lines between the first two headers from CHANGELOG.md, # and use it as a description for the new release. CHANGELOG=$(awk 'BEGIN { first = 0 } /^# / { if (first == 0) { first = 1 } else { exit } } /^[^#]/ { print $0 }' CHANGELOG.md)