This commit is contained in:
@@ -14,6 +14,7 @@ jobs:
|
|||||||
uses: https://git.daemonlord.ru/actions/checkout@v4
|
uses: https://git.daemonlord.ru/actions/checkout@v4
|
||||||
with:
|
with:
|
||||||
fetch-depth: 0
|
fetch-depth: 0
|
||||||
|
tags: true
|
||||||
|
|
||||||
- name: Set up JDK 17
|
- name: Set up JDK 17
|
||||||
uses: https://git.daemonlord.ru/actions/setup-java@v4
|
uses: https://git.daemonlord.ru/actions/setup-java@v4
|
||||||
@@ -30,9 +31,11 @@ jobs:
|
|||||||
- name: Check if tag exists
|
- name: Check if tag exists
|
||||||
run: |
|
run: |
|
||||||
VERSION=$(cat version.txt)
|
VERSION=$(cat version.txt)
|
||||||
if git rev-parse "$VERSION" >/dev/null 2>&1; then
|
if git show-ref --tags --quiet --verify "refs/tags/$VERSION"; then
|
||||||
|
echo "Tag '$VERSION' already exists."
|
||||||
echo "exists=true" > tag_exists.txt
|
echo "exists=true" > tag_exists.txt
|
||||||
else
|
else
|
||||||
|
echo "Tag '$VERSION' does not exist yet."
|
||||||
echo "exists=false" > tag_exists.txt
|
echo "exists=false" > tag_exists.txt
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@@ -40,9 +43,12 @@ jobs:
|
|||||||
run: |
|
run: |
|
||||||
EXISTS=$(cat tag_exists.txt)
|
EXISTS=$(cat tag_exists.txt)
|
||||||
if [ "$EXISTS" = "true" ]; then
|
if [ "$EXISTS" = "true" ]; then
|
||||||
echo "Version already released, skipping."
|
echo "Version already released, skipping workflow."
|
||||||
exit 0
|
exit 0
|
||||||
|
else
|
||||||
|
echo "Version not released yet, continuing workflow..."
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
||||||
- name: Decode keystore
|
- name: Decode keystore
|
||||||
run: |
|
run: |
|
||||||
|
|||||||
Reference in New Issue
Block a user