Skip to content

release_library

release_library #198

Workflow file for this run

name: Release Library
on:
repository_dispatch:
types:
- release_library
jobs:
build:
name: Create Library Release
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
ref: master
- name: Prepare Data
id: data
run: |
echo "type=$(echo ${{ github.event.client_payload.ref }} | cut -d'/' -f2)" >> $GITHUB_OUTPUT
echo "tag=$(echo ${{ github.event.client_payload.ref }} | cut -d'/' -f3)" >> $GITHUB_OUTPUT
- name: Tag latest commit
id: tag_release
if: steps.data.outputs.type == 'tags'
run: |
git config --global user.email "[email protected]"
git config --global user.name "GitHub Actions"
git tag -a ${{ steps.data.outputs.tag }} -m "[RELEASE] ${{ steps.data.outputs.tag }}"
git push --tags
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Upload release notes
if: steps.data.outputs.type == 'tags'
uses: Roang-zero1/github-create-release-action@master
with:
created_tag: ${{ steps.data.outputs.tag }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}