Skip to content

Commit 4439c6f

Browse files
committed
Remove old checks on check-release.sh
1 parent 4a67bbf commit 4439c6f

File tree

1 file changed

+5
-11
lines changed

1 file changed

+5
-11
lines changed

.github/scripts/check-release.sh

Lines changed: 5 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -4,25 +4,19 @@
44
current_tag=$(echo $GITHUB_REF | cut -d '/' -f 3 | sed -r 's/^v//')
55

66
file1='pubspec.yaml'
7-
file2='example/pubspec.yaml'
8-
file3='example/pubspec.lock'
9-
file4='README.md'
10-
file5='lib/src/version.dart'
7+
file2='README.md'
8+
file3='lib/src/version.dart'
119
changelog_file='CHANGELOG.md'
1210
ret=0
1311

1412
file_tag1=$(grep '^version: ' $file1 | cut -d ':' -f 2 | tr -d ' ')
15-
file_tag2=$(grep 'meilisearch: "' $file2 | cut -d ':' -f 2 | tr -d '"' | tr -d ' ')
16-
file_tag3=$(grep 'meilisearch' -A 6 $file3 | grep 'version: ' | cut -d ':' -f2 | tr -d '"' | tr -d ' ')
17-
file_tag4=$(grep 'meilisearch: ' $file4 | cut -d '^' -f2)
18-
file_tag5=$(grep -o "[0-9\.]" $file5 | tr -d '[:space:]')
19-
if [ "$current_tag" != "$file_tag1" ] || [ "$current_tag" != "$file_tag2" ] || [ "$current_tag" != "$file_tag3" ] || [ "$current_tag" != "$file_tag4" ] || [ "$current_tag" != "$file_tag5" ]; then
13+
file_tag2=$(grep 'meilisearch: ' $file2 | cut -d '^' -f2)
14+
file_tag3=$(grep -o "[0-9\.]" $file3 | tr -d '[:space:]')
15+
if [ "$current_tag" != "$file_tag1" ] || [ "$current_tag" != "$file_tag2" ] || [ "$current_tag" != "$file_tag3" ]; then
2016
echo "Error: the current tag does not match the version in package file(s)."
2117
echo "$file1: found $file_tag1 - expected $current_tag"
2218
echo "$file2: found $file_tag2 - expected $current_tag"
2319
echo "$file3: found $file_tag3 - expected $current_tag"
24-
echo "$file4: found $file_tag4 - expected $current_tag"
25-
echo "$file5: found $file_tag5 - expected $current_tag"
2620
ret=1
2721
fi
2822

0 commit comments

Comments
 (0)