Skip to content

Commit b2128dc

Browse files
author
Mindee
committed
🔖 Version 4.15.0
1 parent 2d36762 commit b2128dc

File tree

1 file changed

+5
-7
lines changed

1 file changed

+5
-7
lines changed

.github/workflows/tag-version.yml

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -8,18 +8,16 @@ on:
88
jobs:
99
tag-version:
1010
runs-on: ubuntu-latest
11+
if: "contains(github.event.head_commit.message, ':bookmark: Version ')"
12+
1113
steps:
1214
- uses: actions/checkout@v4
1315

14-
- name: Get version
15-
id: get_version
16+
- name: Tag version
1617
run: |
1718
msg_start=':bookmark: Version '
18-
version=$(\
19-
git log -1 --skip=0 --pretty=%s |\
20-
grep -oP "(?<=${msg_start})[0-9]{1,}\.[0-9]{1,}\.[0-9]{1,}" |\
21-
true\
22-
)
19+
version_format='[0-9]{1,}\.[0-9]{1,}\.[0-9]{1,}'
20+
version=$(git log -1 --skip=0 --pretty=%s | grep -oP "(?<=${msg_start})${version_format}")
2321
2422
if [ -z "${version}" ]; then
2523
echo 'Version not found, exiting.'

0 commit comments

Comments
 (0)