Skip to content

Merge pull request #3 from onemedical/INFRA-5855 #4

Merge pull request #3 from onemedical/INFRA-5855

Merge pull request #3 from onemedical/INFRA-5855 #4

# Create a new GitHub tag and release based on a value in version file.
---
name: 🏷 Tag and Release
on:
push:
paths:
- version
branches:
- main
jobs:
tag-and-release:
runs-on: ubuntu-latest
steps:
- name: 📥 Check out code
uses: actions/checkout@v3
- name: 🏷 Create a tag
id: create-tag
uses: butlerlogic/action-autotag@stable
with:
strategy: regex
root: "version"
regex_pattern: "(\\d+\\.\\d+\\.\\d+)"
tag_prefix: "v"
env:
GITHUB_TOKEN: "${{ secrets.GITHUB_TOKEN }}"
- name: 🦄 Create a release
uses: ncipollo/release-action@v1
with:
generateReleaseNotes: true
tag: ${{ steps.create-tag.outputs.tagname }}
token: ${{ secrets.GITHUB_TOKEN }}