From 7e1149d57a4a4cdce0777a6f57b7107e1efc08dc Mon Sep 17 00:00:00 2001 From: Adam Chelminski Date: Thu, 13 Jun 2019 11:07:12 -0400 Subject: [PATCH] STITCH-2966 Fix release scripts to properly handle tagging after squash and merge --- contrib/docs-examples/checksum | 2 +- contrib/publish_sdk.sh | 11 +++++++++++ 2 files changed, 12 insertions(+), 1 deletion(-) diff --git a/contrib/docs-examples/checksum b/contrib/docs-examples/checksum index 0b245021b..8b9f288d7 100644 --- a/contrib/docs-examples/checksum +++ b/contrib/docs-examples/checksum @@ -1 +1 @@ -b9209ed9408e9a0da1e4361e164db43d \ No newline at end of file +339650df9bc614a8bfd4abdc4400bc03 \ No newline at end of file diff --git a/contrib/publish_sdk.sh b/contrib/publish_sdk.sh index f60f99047..4030a9abc 100755 --- a/contrib/publish_sdk.sh +++ b/contrib/publish_sdk.sh @@ -7,4 +7,15 @@ DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )" cd $DIR cd .. +CURRENT_VERSION=`node -e 'console.log(require("./lerna.json").version)'` + +# Delete the version tag that was generated by "lerna version" +git tag --delete "v$CURRENT_VERSION" +git push --delete upstream "v$CURRENT_VERSION" + +# Tag the current commit as the new version +git tag "v$CURRENT_VERSION" +git push upstream "v$CURRENT_VERSION" + +# Publish the SDK from the current git HEAD lerna publish from-git