Skip to content

Commit 748ea14

Browse files
committed
Cleanup stderr in publish scripts
1 parent 5d52f2a commit 748ea14

File tree

2 files changed

+7
-2
lines changed

2 files changed

+7
-2
lines changed

scripts/update-npm-package-access.js

+4-1
Original file line numberDiff line numberDiff line change
@@ -62,8 +62,11 @@ void (async () => {
6262
)
6363
logger.log(stdout)
6464
} catch (e) {
65+
const stderr = e?.stderr ?? ''
6566
fails.push(pkg.printName)
66-
logger.log(e)
67+
if (stderr) {
68+
logger.log(stderr)
69+
}
6770
}
6871
})
6972

scripts/update-npm-package-publish.js

+3-1
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,9 @@ async function publish(pkg, state = { fails: [] }) {
8484
const stderr = e?.stderr ?? ''
8585
if (!stderr.includes('cannot publish over')) {
8686
state.fails.push(pkg.printName)
87-
logger.log(stderr)
87+
if (stderr) {
88+
logger.log(stderr)
89+
}
8890
}
8991
}
9092
}

0 commit comments

Comments
 (0)