Skip to content

Commit cafb1fd

Browse files
committed
Set PIPELINE_UUID= earlier in the file
1 parent 465a8e9 commit cafb1fd

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

entrypoint.sh

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -295,16 +295,18 @@ if [[ -z "${INPUT_PIPELINE:-}" ]] && [[ -z "${INPUT_PIPELINE_UUID:-}" ]]; then
295295
exit 1
296296
fi
297297

298+
ORG_SLUG=""
299+
PIPELINE_SLUG=""
300+
PIPELINE_UUID=""
301+
BUILD_URL=""
302+
298303
if [[ -n "${INPUT_PIPELINE_UUID:-}" ]]; then
299304
PIPELINE_UUID="${INPUT_PIPELINE_UUID}"
300305
BUILD_URL="https://api.buildkite.com/v2/pipelines/${PIPELINE_UUID}/builds"
301-
ORG_SLUG=""
302-
PIPELINE_SLUG=""
303306
else
304307
ORG_SLUG=$(echo "${INPUT_PIPELINE}" | cut -d'/' -f1)
305308
PIPELINE_SLUG=$(echo "${INPUT_PIPELINE}" | cut -d'/' -f2)
306309
BUILD_URL="https://api.buildkite.com/v2/organizations/${ORG_SLUG}/pipelines/${PIPELINE_SLUG}/builds"
307-
PIPELINE_UUID=""
308310
fi
309311

310312
COMMIT="${INPUT_COMMIT:-${GITHUB_SHA}}"

0 commit comments

Comments
 (0)