mirror of
https://github.com/harivansh-afk/deskctl.git
synced 2026-04-15 07:04:46 +00:00
fix ci tag mismatch
This commit is contained in:
parent
ae5eb21563
commit
08d8402afc
1 changed files with 9 additions and 1 deletions
10
.github/workflows/ci.yml
vendored
10
.github/workflows/ci.yml
vendored
|
|
@ -126,6 +126,12 @@ jobs:
|
||||||
NEW="${MAJOR}.${MINOR}.${NEW_PATCH}"
|
NEW="${MAJOR}.${MINOR}.${NEW_PATCH}"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
# Ensure the computed version does not already have a tag
|
||||||
|
while git rev-parse "v${NEW}" >/dev/null 2>&1; do
|
||||||
|
IFS='.' read -r MAJOR MINOR PATCH <<< "$NEW"
|
||||||
|
NEW="${MAJOR}.${MINOR}.$((PATCH + 1))"
|
||||||
|
done
|
||||||
|
|
||||||
echo "version=${NEW}" >> "$GITHUB_OUTPUT"
|
echo "version=${NEW}" >> "$GITHUB_OUTPUT"
|
||||||
echo "tag=v${NEW}" >> "$GITHUB_OUTPUT"
|
echo "tag=v${NEW}" >> "$GITHUB_OUTPUT"
|
||||||
|
|
||||||
|
|
@ -223,7 +229,9 @@ jobs:
|
||||||
git commit -m "release: ${{ needs.changes.outputs.tag }} [skip ci]"
|
git commit -m "release: ${{ needs.changes.outputs.tag }} [skip ci]"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
git tag "${{ needs.changes.outputs.tag }}"
|
if ! git rev-parse "${{ needs.changes.outputs.tag }}" >/dev/null 2>&1; then
|
||||||
|
git tag "${{ needs.changes.outputs.tag }}"
|
||||||
|
fi
|
||||||
git push origin main --tags
|
git push origin main --tags
|
||||||
|
|
||||||
release:
|
release:
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue