Skip to content
This repository was archived by the owner on Jun 10, 2025. It is now read-only.

Commit 35125bb

Browse files
Release 1.0.1
1 parent a934ea1 commit 35125bb

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

.github/scripts/check_version.sh

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -7,16 +7,16 @@ version=`grep "^version" gradle.properties | cut -d= -f2 | tr -d "[:space:]"`
77
echo "Version in 'gradle.properties' file: '$version'"
88

99
if [ "$tag" != "" ]; then
10+
echo "Release mode: check version consistency..."
1011
if [ "$tag" != "$version" ]; then
1112
echo "ERROR: the tag '$tag' is different from the version '$version' in the 'gradle.properties' file"
1213
exit 1
1314
fi
14-
fi
15-
16-
echo "Fetch tags..."
17-
git fetch --tags
18-
19-
if [ $(git tag -l "$version") ]; then
20-
echo "ERROR: version '$version' has already been released"
21-
exit 1
15+
else
16+
echo "Snapshot mode: fetch existing tags..."
17+
git fetch --tags
18+
if [ $(git tag -l "$version") ]; then
19+
echo "ERROR: version '$version' has already been released"
20+
exit 1
21+
fi
2222
fi

0 commit comments

Comments
 (0)