Files
omni-launcher/.gitea/workflows/tag-on-bump.yml
T
Radu Macocian cf62443ec2
Tag on version bump / tag (push) Successful in 18s
Added theme engine support and aur publish pipeline
2026-06-09 13:48:09 +02:00

41 lines
1.2 KiB
YAML

name: Tag on version bump
on:
push:
branches: [master]
jobs:
tag:
runs-on: ubuntu-latest
container:
image: archlinux:latest
defaults:
run:
shell: bash
steps:
- name: Install dependencies
run: pacman -Syu --noconfirm --needed git
- name: Checkout source
run: |
git clone --branch ${{ gitea.ref_name }} \
http://gitea-actions:${{ gitea.token }}@gitea:3030/${{ gitea.repository }}.git .
- name: Tag if pkgver bumped
run: |
set -euo pipefail
PKGVER=$(awk -F= '/^pkgver=/{print $2}' PKGBUILD)
TAG="v${PKGVER}"
git config --global --add safe.directory "$(pwd)"
git fetch --tags origin
if git rev-parse -q --verify "refs/tags/${TAG}" >/dev/null; then
echo "Tag ${TAG} already exists, nothing to do."
exit 0
fi
git config user.name "${{ vars.AUR_GIT_NAME || 'Radu Macocian' }}"
git config user.email "${{ vars.AUR_GIT_EMAIL || 'radu@macocian.com' }}"
git tag -a "${TAG}" -m "Release ${TAG}"
git push \
http://gitea-actions:${{ gitea.token }}@gitea:3030/${{ gitea.repository }}.git \
"${TAG}"