Skip to content

Commit 649c12f

Browse files
authored
Fix the script to publish the package (#101)
1 parent b4f52e2 commit 649c12f

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

.github/scripts/check-release.sh

+1-4
Original file line numberDiff line numberDiff line change
@@ -2,9 +2,6 @@
22

33
# Checking if current tag matches the package version
44
current_tag=$(echo $GITHUB_REF | tr -d 'refs/tags/v')
5-
major=$(echo $current_tag | cut -d '.' -f1 )
6-
minor=$(echo $current_tag | cut -d '.' -f2 )
7-
round_current_tag="$major.$minor.0"
85

96
file1='pubspec.yaml'
107
file2='example/pubspec.yaml'
@@ -17,7 +14,7 @@ file_tag1=$(grep '^version: ' $file1 | cut -d ':' -f 2 | tr -d ' ')
1714
file_tag2=$(grep 'meilisearch: "' $file2 | cut -d ':' -f 2 | tr -d '"' | tr -d ' ')
1815
file_tag3=$(grep 'meilisearch' -A 6 $file3 | grep 'version: ' | cut -d ':' -f2 | tr -d '"' | tr -d ' ')
1916
file_tag4=$(grep 'meilisearch: ' $file4 | cut -d '^' -f2)
20-
if [ "$current_tag" != "$file_tag1" ] || [ "$current_tag" != "$file_tag2" ] || [ "$current_tag" != "$file_tag3" ] || [ "$round_current_tag" != "$file_tag4" ]; then
17+
if [ "$current_tag" != "$file_tag1" ] || [ "$current_tag" != "$file_tag2" ] || [ "$current_tag" != "$file_tag3" ] || [ "$current_tag" != "$file_tag4" ]; then
2118
echo "Error: the current tag does not match the version in package file(s)."
2219
echo "$file1: found $file_tag1 - expected $current_tag"
2320
echo "$file2: found $file_tag2 - expected $current_tag"

0 commit comments

Comments
 (0)