From 4c76df565f2155e839e42941b5b956c07ca75d06 Mon Sep 17 00:00:00 2001 From: "Eric L. Goldstein" <3359116+mangs@users.noreply.github.com> Date: Fri, 29 Mar 2024 17:22:42 -0400 Subject: [PATCH] fix publish (#58) --- scripts/publishReleaseNotes.mjs | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/scripts/publishReleaseNotes.mjs b/scripts/publishReleaseNotes.mjs index a0fa37b..599d296 100755 --- a/scripts/publishReleaseNotes.mjs +++ b/scripts/publishReleaseNotes.mjs @@ -104,14 +104,13 @@ try { 'Content-Type': 'application/json', // 'User-Agent': repositoryMetadata, }, + method: 'POST', }); console.log('✅ SUCCESS CREATING RELEASE'); prettyPrintJson(response); } catch (error) { console.error('❌ ERROR CREATING RELEASE'); - prettyPrintJson(error); - // eslint-disable-next-line n/no-process-exit -- stack trace not useful here - process.exit(1); + throw error; } // Update the latest major tag version to the latest commit SHA @@ -136,13 +135,12 @@ try { 'Content-Type': 'application/json', // 'User-Agent': repositoryMetadata, }, + method: 'PATCH', }, ); console.log('✅ SUCCESS UPDATING MAJOR TAG'); prettyPrintJson(response); } catch (error) { console.error('❌ ERROR UPDATING MAJOR TAG'); - prettyPrintJson(error); - // eslint-disable-next-line n/no-process-exit -- stack trace not useful here - process.exit(1); + throw error; }