Skip to content

Commit

Permalink
chore: fix internal packages release script [skip ci]
Browse files Browse the repository at this point in the history
  • Loading branch information
tsirlucas committed Jul 13, 2021
1 parent e0afdd5 commit a5995bf
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions package/bin/release.sh
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,11 @@
set -eux

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

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

cd ../expo-package
Expand All @@ -18,7 +19,6 @@ else
cd native-package
npm publish


cd ../expo-package
npm publish
fi
Expand Down

0 comments on commit a5995bf

Please sign in to comment.