From 67d338fc425b27a462f49547bce5915b62564145 Mon Sep 17 00:00:00 2001 From: jamie Date: Tue, 3 Aug 2021 12:27:35 +0100 Subject: [PATCH] Catch errors properly --- README.md | 2 +- src/index.ts | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index 2eb880c..353c401 100644 --- a/README.md +++ b/README.md @@ -9,7 +9,7 @@ Add the following to your `pipeline.yml`: ```yml steps: - plugins: - - wellcomecollection/github-deployments#v0.1.1: + - wellcomecollection/github-deployments#v0.1.2: ref: ${BUILDKITE_COMMIT} environment: stage ``` diff --git a/src/index.ts b/src/index.ts index 133132a..7edcb5d 100644 --- a/src/index.ts +++ b/src/index.ts @@ -47,4 +47,7 @@ const main = async () => { } }; -main(); +main().catch((error) => { + console.error(error); + process.exitCode = 1; +});