fix(semver): use a.b.c-d version pattern instead of a.b.c.d for extra releases

This commit is contained in:
Ivan Dyachkov 2023-08-09 14:45:34 +02:00
parent c587a753da
commit 42b0a131ce
2 changed files with 4 additions and 4 deletions

View File

@ -20,7 +20,7 @@ if [[ $1 =~ ^refs/tags/v[5-9]+\.[0-9]+\.[0-9]+$ ]]; then
PROFILE=emqx
RELEASE=true
LATEST=$(is_latest "$1")
elif [[ $1 =~ ^refs/tags/v[5-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
elif [[ $1 =~ ^refs/tags/v[5-9]+\.[0-9]+\.[0-9]+-[0-9]+$ ]]; then
PROFILE=emqx
RELEASE=true
LATEST=$(is_latest "$1")
@ -28,7 +28,7 @@ elif [[ $1 =~ ^refs/tags/e[5-9]+\.[0-9]+\.[0-9]+$ ]]; then
PROFILE=emqx-enterprise
RELEASE=true
LATEST=$(is_latest "$1")
elif [[ $1 =~ ^refs/tags/e[5-9]+\.[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
elif [[ $1 =~ ^refs/tags/e[5-9]+\.[0-9]+\.[0-9]+-[0-9]+$ ]]; then
PROFILE=emqx-enterprise
RELEASE=true
LATEST=$(is_latest "$1")

View File

@ -13,7 +13,7 @@ Unrecognized git ref: v5.2.0
{"profile": "emqx", "release": true, "latest": false}
>>>= 0
./parse-git-ref.sh refs/tags/v5.1.5.1
./parse-git-ref.sh refs/tags/v5.1.5-1
>>>
{"profile": "emqx", "release": true, "latest": false}
>>>= 0
@ -43,7 +43,7 @@ Unrecognized tag: refs/tags/v5.2.0-alpha-1
{"profile": "emqx-enterprise", "release": true, "latest": false}
>>>= 0
./parse-git-ref.sh refs/tags/e5.1.5.1
./parse-git-ref.sh refs/tags/e5.1.5-1
>>>
{"profile": "emqx-enterprise", "release": true, "latest": false}
>>>= 0