Skip to content

Commit

Permalink
chore: fixed ./bin/publish exit status when npm publish fails
Browse files Browse the repository at this point in the history
  • Loading branch information
lquixada committed Dec 21, 2024
1 parent 3415e1f commit 60781b9
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions bin/publish
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,10 @@ latest_major=$(echo $latest_version | cut -d. -f1)

# If this has been triggered by a "vX.x-test" branch, we just want to test the release workflow (dry run it!)
if [[ "$workflow_version" == *"-test"* ]]; then
npm publish --tag $workflow_track --dry-run && \
exit 0
npm publish --tag $workflow_track --dry-run && exit 0
fi

npm publish --tag $workflow_track
npm publish --tag $workflow_track || exit 1

if [[ "$workflow_major" == "$latest_major" ]]; then
npm dist-tag add cross-fetch@$workflow_version latest
Expand Down

0 comments on commit 60781b9

Please sign in to comment.