From 951724de2ee7811de0ba5ca86452f9b35033c549 Mon Sep 17 00:00:00 2001 From: Gabe Goodhart Date: Thu, 5 Aug 2021 14:24:18 -0600 Subject: [PATCH] BuildBeforePublish: Fix removal of temporary package.json --- src/ts/ci/publish.sh | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/ts/ci/publish.sh b/src/ts/ci/publish.sh index abb5e91..f44391f 100755 --- a/src/ts/ci/publish.sh +++ b/src/ts/ci/publish.sh @@ -19,11 +19,12 @@ fi version_placeholder="0.0.0-REPLACEME" if [[ "$OSTYPE" == "darwin"* ]] then - sed_cmd="sed -i ''" + sed_cmd="sed -i .bak" else - sed_cmd="sed -i''" + sed_cmd="sed -i.bak" fi $sed_cmd "s,$version_placeholder,$TS_RELEASE_VERSION,g" package.json +rm package.json.bak # If this is a dry run, add the flag dry_run_flag="" @@ -41,3 +42,4 @@ npm publish $dry_run_flag # Replace the placeholder $sed_cmd "s,$TS_RELEASE_VERSION,$version_placeholder,g" package.json +rm package.json.bak