From 54561582e618852bf98df590ef94ee163c3253dc Mon Sep 17 00:00:00 2001 From: GlacierWalrus <114941647+GlacierWalrus@users.noreply.github.com> Date: Fri, 10 Feb 2023 15:00:33 +0000 Subject: [PATCH] Set PR_NUMBER when PR is created --- entrypoint.sh | 1 + 1 file changed, 1 insertion(+) diff --git a/entrypoint.sh b/entrypoint.sh index cdd919f..63329f3 100755 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -169,6 +169,7 @@ if [[ -z "${PR_NUMBER}" ]]; then COMMAND="hub pull-request -b ${TARGET_BRANCH} -h ${SOURCE_BRANCH} --no-edit ${ARG_LIST[@]}" echo -e "\nRunning: ${COMMAND}" URL=$(sh -c "${COMMAND}") + PR_NUMBER=$(gh pr view --json number -q .number ${URL}) # shellcheck disable=SC2181 if [[ "$?" != "0" ]]; then RET_CODE=1; fi else