From 4c5a49d6852b6409bb73dd231d3ee79e872a7d09 Mon Sep 17 00:00:00 2001 From: Micheal Wilkinson Date: Fri, 20 Mar 2026 22:46:44 +0000 Subject: [PATCH] fix: fall back to git tag on HEAD when version input is not propagated --- publish/action.yml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/publish/action.yml b/publish/action.yml index 69d00e4..2c8c5b8 100644 --- a/publish/action.yml +++ b/publish/action.yml @@ -52,6 +52,9 @@ runs: elif [[ "${GITHUB_REF_VALUE}" == refs/tags/* ]]; then tag="${GITHUB_REF_VALUE#refs/tags/}" normalized="${tag#v}" + elif head_tag="$(git describe --exact-match --tags HEAD 2>/dev/null)" && [[ -n "$head_tag" ]]; then + tag="$head_tag" + normalized="${tag#v}" else echo "A version input is required when the workflow is not running from a tag push" >&2 exit 1