Skip to content

Update README.md

Update README.md #5

Workflow file for this run

name: Tag with Latest Version on PR Merge
on:
pull_request:
types: [ closed ]
jobs:
tag-on-merge:
if: github.event.pull_request.merged == true && github.event.pull_request.base.ref == 'main'
runs-on: ubuntu-latest
steps:
- uses: step-security/harden-runner@91182cccc01eb5e619899d80e4e971d6181294a7 # v2.10.1
with:
egress-policy: audit
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Python
uses: actions/setup-python@0b93645e9fea7318ecaed2b359559ac225c90a2b
with:
python-version: '3.11'
- name: Install Requirements
run: |
pip install --upgrade pip poetry
- name: Set up Git
run: |
git config user.name "dac-bot[bot]"
git config user.email "[email protected]"
- name: Check and update tag
run: |
VERSION="v$(poetry version --short)"
if [[ $(git tag -l $VERSION) ]]; then
echo "Tag $VERSION already exists"
else
echo "Tagging with $VERSION"
git tag "$VERSION"
git push origin --tags
fi