From 52dfdc04865c18e296a0c4ce9cfa2ce72a380829 Mon Sep 17 00:00:00 2001 From: Rosie Le Faive Date: Wed, 25 Oct 2023 13:08:42 -0300 Subject: [PATCH] Use `$GITHUB_REF_NAME` to work with both branches and tags. --- entrypoint.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/entrypoint.sh b/entrypoint.sh index 95f352a..9fdf5b5 100755 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -22,7 +22,7 @@ DEFAULT_POLL_TIMEOUT=10 POLL_TIMEOUT=${POLL_TIMEOUT:-$DEFAULT_POLL_TIMEOUT} sh -c "git config --global --add safe.directory /github/workspace" -git checkout "${GITHUB_REF:11}" +git checkout "$GITHUB_REF_NAME" branch="$(git symbolic-ref --short HEAD)" branch_uri="$(urlencode ${branch})"