feat(gha): init release workflow

Signed-off-by: Antoine Barthelemy <antoine@linux.com>
This commit is contained in:
Antoine Barthelemy 2023-10-26 15:03:31 +02:00
parent 6b016a1db7
commit 94636598dd
No known key found for this signature in database
GPG key ID: B86420F9D5C0BCAC

21
.github/workflows/retag.yml vendored Normal file
View file

@ -0,0 +1,21 @@
name: Retag
on:
push:
tags:
- 'v[1-2].[0-9]+.[0-9]+*'
defaults:
run:
shell: bash
jobs:
tag:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- run: |
set -o pipefail
git tag --force "$(grep '^v[1-2]\.[0-9]\+\.[0-9]\+\(.*\)\?$' <<< ${GITHUB_REF#refs/*/} | sed 's/^v\([1-2]\)\..*/v\1/')"
git push --tag --force