Skip to content

Commit a12fc0a

Browse files
authored
Merge pull request #73 from renderbox/develop
Develop
2 parents aef6644 + e0c048f commit a12fc0a

File tree

1 file changed

+13
-2
lines changed

1 file changed

+13
-2
lines changed

.github/workflows/python-publish.yml

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,19 +22,27 @@ jobs:
2222
with:
2323
python-version: "3.10"
2424

25+
- name: current_version
26+
run: echo "current_version=$(grep 'version = ' pyproject.toml | cut -d '=' -f2 | tr -d ' "')" >> $GITHUB_ENV
27+
2528
- name: Install bump2version
2629
run: pip install bump2version
2730

2831
- name: Bump version and commit changes
2932
run: |
33+
git config --global user.name 'github-actions[bot]'
34+
git config --global user.email 'github-actions[bot]@users.noreply.github.com'
3035
bump2version patch
3136
env:
3237
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
3338

39+
- name: new_version
40+
run: echo "new_version=$(grep 'version = ' pyproject.toml | cut -d '=' -f2 | tr -d ' "')" >> $GITHUB_ENV
41+
3442
- name: Push changes
3543
run: |
36-
git config user.name 'github-actions[bot]'
37-
git config user.email 'github-actions[bot]@users.noreply.github.com'
44+
git config --global user.name 'github-actions[bot]'
45+
git config --global user.email 'github-actions[bot]@users.noreply.github.com'
3846
git push
3947
git push --tags
4048
env:
@@ -43,6 +51,9 @@ jobs:
4351
build:
4452
name: Build distribution 📦
4553
runs-on: ubuntu-latest
54+
# Only run this job when the `bump_version` job is successful
55+
needs:
56+
- bump_version
4657

4758
steps:
4859
- uses: actions/checkout@v4

0 commit comments

Comments
 (0)