diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index ae535df4a..0e117b863 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -110,7 +110,7 @@ jobs: git config --global user.name silverhand-bot - name: Publish - run: node .script/publish.js + run: node .scripts/publish.js create-github-release: environment: release diff --git a/.scripts/publish.js b/.scripts/publish.js index 4213897b8..95f3cd5e3 100644 --- a/.scripts/publish.js +++ b/.scripts/publish.js @@ -50,5 +50,10 @@ if (taggedPackages.length === 0) { process.exit(0); } -execSync('pnpm -r publish'); -execSync('git push --follow-tags'); +try { + execSync('pnpm -r publish'); + execSync('git push --follow-tags'); +} catch (error) { + console.log(String(error.stdout)); + throw error; +}