Skip to content

Commit e4e7f82

Browse files
committed
chore: add version bumping
1 parent ea64254 commit e4e7f82

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

.github/workflows/python-release.yaml

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,24 @@ jobs:
3838
with:
3939
python-version: 3.x
4040

41+
- name: Get current version
42+
id: get_version
43+
working_directory: impit-python
44+
run: |
45+
echo "current_version=$(uvx --from=toml-cli toml get --toml-path=pyproject.toml project.version)" >> "$GITHUB_OUTPUT"
46+
47+
- name: Increment version
48+
id: increment_version
49+
working_directory: impit-python
50+
run: |
51+
echo "new_version=$(npx semver -i ${ { github.event.inputs.bump } } ${{ steps.get_version.outputs.current_version }})" >> "$GITHUB_OUTPUT"
52+
53+
- name: Show new version
54+
id: show_new_version
55+
working_directory: impit-python
56+
run: |
57+
echo "New version is ${{ steps.increment_version.outputs.new_version }}"
58+
4159
- name: Download all artifacts
4260
uses: actions/download-artifact@v4
4361
with:

0 commit comments

Comments
 (0)