Skip to content

Commit

Permalink
fix: work with tags event
Browse files Browse the repository at this point in the history
  • Loading branch information
georeith committed Sep 5, 2024
1 parent cd15dc0 commit 886f50a
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,10 @@ push_to_branch() {
git config --global user.name "${INPUT_GITHUB_USER_NAME}"

if [ "$INPUT_SKIP_REF_CHECKOUT" != true ]; then
git checkout "${GITHUB_HEAD_REF:-${GITHUB_REF#refs/heads/}}"
CHECKOUT=${GITHUB_HEAD_REF:-${GITHUB_REF}}
CHECKOUT=${CHECKOUT#refs/heads/}
CHECKOUT=${CHECKOUT#refs/tags/}
git checkout "${CHECKOUT}"
fi

if [ -n "$(git show-ref refs/heads/${BRANCH})" ]; then
Expand Down

0 comments on commit 886f50a

Please sign in to comment.