Skip to content
name: Update version reference
on:
release:
types: [published]
jobs:
update-ref:
name: Update reference
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Extract major version from tag
id: extract-version
run: |
FULL_VERSION=${GITHUB_REF##*/}
MAJOR_VERSION=$(echo "${FULL_VERSION%.*.*}")
echo "TAG_NAME=${MAJOR_VERSION}" >> $GITHUB_OUTPUT
- name: Update reference to latest version
uses: richardsimko/update-tag@main
with:
tag_name: ${{ steps.extract-version.outputs.TAG_NAME }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Update reference to latest version
uses: richardsimko/update-tag@main
with:
tag_name: latest
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}