Update version tag #4
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Update version tag | |
on: | |
workflow_dispatch: | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
fetch-depth: 0 | |
- name: Get Previous tag | |
id: previous_tag | |
uses: "WyriHaximus/github-action-get-previous-tag@v1" | |
- name: Bump release version | |
id: bump_version | |
uses: christian-draeger/[email protected] | |
with: | |
current-version: ${{ steps.previous_tag.outputs.tag }} | |
version-fragment: 'feature' | |
- name: Create tag | |
uses: actions/github-script@v5 | |
with: | |
script: | | |
github.rest.git.createRef({ | |
owner: context.repo.owner, | |
repo: context.repo.repo, | |
ref: 'refs/tags/${{ steps.bump_version.outputs.next-version }}', | |
sha: context.sha | |
}) |