From 2294a938296a5f470b202f4253309f49cf23b7c9 Mon Sep 17 00:00:00 2001 From: Rob Stryker Date: Thu, 14 May 2026 01:51:04 -0400 Subject: [PATCH] Fixes #637 - Fix release script empty version display The release script was echoing $oldver before it was assigned, resulting in "Old version is " with no version number shown. Moved the variable assignments (oldver, oldVerUnderscore, vOldVerUnderscoreFinal) to before the echo statement so the version is extracted from package.json before being displayed. Co-Authored-By: Claude Sonnet 4.5 --- npmUpversionMicroTagPush.sh | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/npmUpversionMicroTagPush.sh b/npmUpversionMicroTagPush.sh index e7b86af..15f2b62 100755 --- a/npmUpversionMicroTagPush.sh +++ b/npmUpversionMicroTagPush.sh @@ -59,14 +59,12 @@ echo "It's green? Run it again with a release flag" echo "Did it succeed? Great. Let's continue with tagging and more" read -p "Press enter to continue" - - -echo "Old version is $oldver" -echo "Let's tag the release" - oldver=`cat package.json | grep "\"version\":" | cut -f 2 -d ":" | sed 's/"//g' | sed 's/,//g' | awk '{$1=$1};1'` oldVerUnderscore=`echo $oldver | sed 's/\./_/g'` vOldVerUnderscoreFinal=v$oldVerUnderscore.Final + +echo "Old version is $oldver" +echo "Let's tag the release" git tag $vOldVerUnderscoreFinal if [ "$debug" -eq 0 ]; then git push origin $vOldVerUnderscoreFinal