Skip to content

Commit a5995bf

Browse files
committed
chore: fix internal packages release script [skip ci]
1 parent e0afdd5 commit a5995bf

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

package/bin/release.sh

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,10 +6,11 @@
66
set -eux
77

88
PACKAGE_VERSION=$(cat package.json | grep version | head -1 | awk -F: '{ print $2 }' | sed 's/[\",]//g' | tr -d '[[:space:]]')
9-
PACKAGE_TAG=$(echo "$PACKAGE_VERSION" | cut -d"-" -f2 | cut -d"." -f1)
9+
PACKAGE_TAG=$(sed 's/.*-\(.*\)\..*/\1/' <<< "$PACKAGE_VERSION")
1010

11-
if [[ ! -z "${PACKAGE_TAG}" ]]; then
12-
cd native-package
11+
# If tag === version it means that its not a prerelease and shouuld set things to latest
12+
if [[ "${PACKAGE_TAG}" != "${PACKAGE_VERSION}" ]]; then
13+
cd native-package
1314
npm publish --tag="$PACKAGE_TAG"
1415

1516
cd ../expo-package
@@ -18,7 +19,6 @@ else
1819
cd native-package
1920
npm publish
2021

21-
2222
cd ../expo-package
2323
npm publish
2424
fi

0 commit comments

Comments
 (0)