diff --git a/.forgejo/workflows/build-image.yml b/.forgejo/workflows/build-image.yml index e29ec21..7bce056 100644 --- a/.forgejo/workflows/build-image.yml +++ b/.forgejo/workflows/build-image.yml @@ -126,9 +126,10 @@ jobs: id: version run: | if [[ "${{ github.ref_type }}" == "tag" ]]; then - echo "tag_name=${{ github.ref_name }}" >> "$GITHUB_OUTPUT" + TAG_NAME="${{ github.ref_name }}" else - echo "tag_name=dev-$(date +%Y%m%d)" >> "$GITHUB_OUTPUT" + TAG_NAME="dev-$(date +%Y%m%d)-${GITHUB_SHA::7}" + fi echo "tag_name=$TAG_NAME" >> "$GITHUB_OUTPUT" - name: Parse image filename diff --git a/.forgejo/workflows/single-flow.yml b/.forgejo/workflows/single-flow.yml index 280c9d3..5443cbe 100644 --- a/.forgejo/workflows/single-flow.yml +++ b/.forgejo/workflows/single-flow.yml @@ -107,11 +107,11 @@ jobs: id: version run: | if [[ "${{ github.ref_type }}" == "tag" ]]; then - echo "tag_name=${{ github.ref_name }}" >> "$GITHUB_OUTPUT" + TAG_NAME="${{ github.ref_name }}" else - echo "tag_name=dev-$(date +%Y%m%d)" >> "$GITHUB_OUTPUT" + TAG_NAME="dev-$(date +%Y%m%d)-${GITHUB_SHA::7}" + fi echo "tag_name=$TAG_NAME" >> "$GITHUB_OUTPUT" - EOF # - name: Parse image filename # id: image