Skip to content

Commit

Permalink
fix: Improved error on failing pnpm install
Browse files Browse the repository at this point in the history
  • Loading branch information
lachlancollins committed Feb 2, 2024
1 parent c4ce4c9 commit e131671
Showing 1 changed file with 7 additions and 2 deletions.
9 changes: 7 additions & 2 deletions src/publish/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -395,8 +395,13 @@ export const publish = async (options) => {
)
}
if (existsSync(path.resolve(rootDir, 'pnpm-lock.yaml'))) {
console.info('Updating examples to use new package versions...')
execSync('pnpm install')
console.info(' Updating pnpm-lock.yaml...')
try {
execSync('pnpm install')
} catch (/** @type {any} */ err) {
console.error(err.stdout.toString())
process.exit(1)
}
}
}
}
Expand Down

0 comments on commit e131671

Please sign in to comment.