We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 27f58ea commit 7c38c8aCopy full SHA for 7c38c8a
1 file changed
.github/workflows/publish.yml
@@ -69,6 +69,7 @@ jobs:
69
environment: release
70
permissions:
71
id-token: write
72
+ contents: write
73
steps:
74
- uses: actions/checkout@v4
75
@@ -90,3 +91,12 @@ jobs:
90
91
92
- name: Publish to PyPI
93
uses: pypa/gh-action-pypi-publish@release/v1
94
+
95
+ - name: Create and push git tag
96
+ run: |
97
+ VERSION=$(grep '^version = ' pyproject.toml | grep -oE '[0-9]+\.[0-9]+\.[0-9]+')
98
+ TAG="v${VERSION}"
99
+ git config user.name "github-actions[bot]"
100
+ git config user.email "github-actions[bot]@users.noreply.github.com"
101
+ git tag -a "$TAG" -m "Release version $VERSION" ${{ github.sha }}
102
+ git push origin "$TAG"
0 commit comments