ci(patch): use GITHUB_REF instead of rebuilding it from type and name

GITHUB_REF is already the fully qualified ref for both branch and tag events,
so reconstructing refs/heads/$GITHUB_REF_NAME and refs/tags/$GITHUB_REF_NAME
just risks the two drifting apart. Keep the type check, since it still decides
whether the develop fallback applies, and take the ref verbatim.
This commit is contained in:
Mihir Kandoi
2026-08-02 22:06:21 +05:30
parent 28d498012a
commit 39b6f37a48

View File

@@ -176,10 +176,10 @@ jobs:
frappe_ref="refs/heads/$GITHUB_BASE_REF"
fallback_to_develop=1
elif [ "${GITHUB_REF_TYPE:-}" = "branch" ]; then
frappe_ref="refs/heads/$GITHUB_REF_NAME"
frappe_ref="$GITHUB_REF"
fallback_to_develop=1
elif [ "${GITHUB_REF_TYPE:-}" = "tag" ]; then
frappe_ref="refs/tags/$GITHUB_REF_NAME"
frappe_ref="$GITHUB_REF"
else
echo "Unsupported GitHub ref type: '${GITHUB_REF_TYPE:-unset}'"
exit 1