Skip to content

add workflow to move tags #2

add workflow to move tags

add workflow to move tags #2

Workflow file for this run

name: Update Major & Minor Release Tag
on:
push:
tags:
- 'v*.*.*'
jobs:
movetag:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Get major version num and update tag
run: |
VERSION=${GITHUB_REF#refs/tags/}
MAJOR=${VERSION%%.*}
MAJOR_MINOR=${VERSION%.*}
git config --global user.name 'appcd-bot'
git config --global user.email 'appcd-bot@users.noreply.github.com'
git tag -fa "${MAJOR}" -m 'Update major version tag'
git tag -fa "${MAJOR_MINOR}" -m 'Update minor version tag'
git push origin "${MAJOR}" --force
git push origin "${MAJOR_MINOR}" --force