ci: adds version calculation via gitversion and autotagging on defaultbranch

This commit is contained in:
Mr. Finch 2025-01-07 12:27:27 +00:00
parent 4f66c686d1
commit e3b97b8adb
4 changed files with 81 additions and 0 deletions

View file

@ -0,0 +1,15 @@
---
.git:create_tag:
image: alpine:3.21
variables:
GIT_STRATEGY: clone
GIT_DEPTH: 0
GIT_LFS_SKIP_SMUDGE: 1
VERSION: ''
TOKEN: '' # Token with push privileges
script:
- apk add git
- git remote set-url origin https://oauth2:$TOKEN@$CI_SERVER_HOST/$CI_PROJECT_PATH
- git tag $VERSION
- git push origin tag $VERSION