Skip to content

Commit

Permalink
chore: semantic-release.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
Roger committed Nov 17, 2023
1 parent 96947dd commit ffb9670
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions .github/workflows/semantic-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,14 @@ jobs:
contents: write

steps:
- name: Check triggered by new release
run: |
if [[ ${{ github.event.head_commit.message }} =~ ^\d+\.\d+\.\d+ ]]; then
echo "Workflow triggered by new realease"
else
echo "Commit message does not match pattern"
fi
- name: Checkout repository
uses: actions/checkout@v4
with:
Expand All @@ -37,6 +45,7 @@ jobs:
pip install -r requirements.txt

- name: Python Semantic Release
if: ${{ ! startsWith(github.event.head_commit.message, '[0-9]+.[0-9]+.[0-9]+') }}
uses: python-semantic-release/python-semantic-release@master
with:
github_token: ${{ secrets.GITHUB_TOKEN }}

0 comments on commit ffb9670

Please sign in to comment.