wrap version variable to prevent script injection

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
This commit is contained in:
Maximilian Dorninger
2025-11-01 18:58:53 +01:00
committed by GitHub
parent e2f3cfd173
commit 568eaa88fe
2 changed files with 4 additions and 4 deletions

View File

@@ -95,9 +95,9 @@ jobs:
id: version
run: |
if [[ "${{ github.event_name }}" == "release" ]]; then
VERSION=${{ github.event.release.tag_name }}
VERSION="${{ github.event.release.tag_name }}"
elif [[ "${{ github.ref_type }}" == "tag" ]]; then
VERSION=${{ github.ref_name }}
VERSION="${{ github.ref_name }}"
else
DATE_STAMP=$(date -u +'%Y.%m.%d')
VERSION="dev-${DATE_STAMP}-${{ github.run_number }}"

View File

@@ -55,9 +55,9 @@ jobs:
id: version
run: |
if [[ "${{ github.event_name }}" == "release" ]]; then
VERSION=${{ github.event.release.tag_name }}
VERSION="${{ github.event.release.tag_name }}"
elif [[ "${{ github.ref_type }}" == "tag" ]]; then
VERSION=${{ github.ref_name }}
VERSION="${{ github.ref_name }}"
else
DATE_STAMP=$(date -u +'%Y.%m.%d')
VERSION="dev-${DATE_STAMP}-${{ github.run_number }}"