Fix: Use consistent version regex for release creation #30
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: Create Release and Tag on Merge | |
on: | |
pull_request: | |
types: [closed] | |
jobs: | |
create-release: | |
if: github.event.pull_request.merged == true && github.event.pull_request.base.ref == 'master' | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
- name: Set up Git | |
run: | | |
git config --global user.name "github-actions[bot]" | |
git config --global user.email "github-actions[bot]@users.noreply.github.com" | |
- uses: paulhatch/[email protected] | |
id: generate-version | |
with: | |
major_pattern: "(MAJOR)" | |
minor_pattern: "(MINOR)" | |
version_format: "st4-${major}.${minor}.${patch}" | |
- name: Create Release | |
id: create-release | |
uses: undergroundwires/[email protected] | |
with: | |
version_regex: "st4-(MAJOR).(MINOR).(PATCH)" | |
git-token: ${{ secrets.ACTION_TOKEN }} | |
release-token: ${{ secrets.ACTION_TOKEN }} |