We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 592457e commit 854b2d2Copy full SHA for 854b2d2
publish.sh
@@ -1,5 +1,11 @@
1
cd reactfire/pub/reactfire
2
3
+# TODO once we go 2.0.0 stable, uncomment
4
+# LATEST_TEST="^[^-]*$"
5
+
6
+# Publish -rc tags on @latest for now
7
+LATEST_TEST="^[^-]*-rc"
8
9
if test $NPM_TOKEN; then
10
11
echo "//registry.npmjs.org/:_authToken=$NPM_TOKEN" > .npmrc
@@ -10,7 +16,14 @@ if test $NPM_TOKEN; then
16
17
if test $TAG_NAME; then
12
18
npm version $(echo $TAG_NAME | sed 's/^v\(.*\)$/\1/')
13
- npm publish . --tag next
19
20
+ if [[ $TAG_NAME =~ $LATEST_TEST]]; then
21
+ NPM_TAG=latest
22
+ else
23
+ NPM_TAG=next
24
+ fi
25
26
+ npm publish . --tag $NPM_TAG
14
27
ret=$?
15
28
else
29
npm version $(npm version | sed -n "s/^ reactfire: '\(.*\)',/\1/p")-canary.$SHORT_SHA
0 commit comments