ci: fix labeling when building on other branches

than github.head_ref, e.g., during release

Signed-off-by: Paul Meyer <49727155+katexochen@users.noreply.github.com>
This commit is contained in:
Paul Meyer 2023-03-07 14:50:16 +01:00
parent e4b5655646
commit cc6006c6ea

View File

@ -69,7 +69,7 @@ runs:
tags=""
sbom=""
if [[ "${{ github.ref_name }}" == "${{ github.event.repository.default_branch }}" ]]; then
if [[ "$(git branch --show-current)" == "${{ github.event.repository.default_branch }}" ]]; then
tags="latest"
else
tags="${{ github.sha }}"