Skip to content

Merge pull request #11 from DiogoRibeiro7/feat/first_commit #10

Merge pull request #11 from DiogoRibeiro7/feat/first_commit

Merge pull request #11 from DiogoRibeiro7/feat/first_commit #10

Workflow file for this run

name: Bump Version on Merge to Main
on:
push:
branches:
- main
jobs:
bump-version:
runs-on: ubuntu-latest
permissions:
contents: write
id-token: write
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.11"
- name: Install Poetry
run: |
curl -sSL https://install.python-poetry.org | python3 -
echo "$HOME/.local/bin" >> $GITHUB_PATH
- name: Install dependencies
run: |
poetry install
poetry add --group dev python-semantic-release
- name: Configure Git user
run: |
git config user.name "github-actions[bot]"
git config user.email "github-actions[bot]@users.noreply.github.com"
- name: Run Semantic Release
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: poetry run semantic-release publish
- name: Push version bump commit and tags
run: |
git pull --ff-only origin main
git push origin main --follow-tags