Skip to content

Commit

Permalink
fix(deploy): improve error message
Browse files Browse the repository at this point in the history
  • Loading branch information
atinux committed Apr 9, 2024
1 parent 67ffd2a commit a8c560e
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion src/commands/deploy.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,12 @@ export default defineCommand({
}
}).catch((err) => {
spinner.fail(`Failed to deploy ${colors.blue(linkedProject.slug)} to ${deployEnvColored}.`)
consola.error(err.message.split('Error: ')[1])
// Error with workers size limit
if (err.message.includes('Error: ')) {
consola.error(err.message.split('Error: ')[1])
} else {
consola.error(err.message.split(' - ')[1] || err.message)
}
process.exit(1)
})
spinner.succeed(`Deployed ${colors.blue(linkedProject.slug)} to ${deployEnvColored}...`)
Expand Down

0 comments on commit a8c560e

Please sign in to comment.