Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Attempt to log when publish fails if is empty and JSON error can't be…
… retrieved from none of those (#844)
  • Loading branch information
Andarist committed Aug 5, 2022
1 parent 7d998ee commit 8627ec1
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/silver-toys-turn.md
@@ -0,0 +1,5 @@
---
"@changesets/cli": patch
---

Attempt to log `stdout` when publish fails if `stderr` is empty and JSON error can't be retrieved from none of those.
2 changes: 1 addition & 1 deletion packages/cli/src/commands/publish/npm-utils.ts
Expand Up @@ -214,7 +214,7 @@ async function internalPublish(
);
}

error(stderr.toString());
error(stderr.toString() || stdout.toString());
return { published: false };
}
return { published: true };
Expand Down

0 comments on commit 8627ec1

Please sign in to comment.