11name : Bump Version and Create Release
22
3+ permissions :
4+ contents : read
5+
36on :
47 push :
58 branches :
@@ -10,27 +13,32 @@ concurrency:
1013 cancel-in-progress : true
1114
1215jobs :
13- bump-and-release :
14- if : " !startsWith(github.event.head_commit.message, 'bump:')"
15- runs-on : ubuntu-latest
16- name : " Bump version and create changelog with commitizen"
17- steps :
18- - uses : actions/checkout@v4
19- with :
20- fetch-depth : 0
21- token : " ${{ secrets.VERSION_BUMP_TAG_TOKEN }}"
22- - name : Create bump and changelog
23- id : cz
24- uses : commitizen-tools/commitizen-action@0.24.0
25- with :
26- commit : true
27- push : true
28- github_token : ${{ secrets.VERSION_BUMP_TAG_TOKEN }}
29- changelog_increment_filename : " release-body.md"
30- - name : Create GitHub Release
31- uses : softprops/action-gh-release@v2
32- with :
33- body_path : " release-body.md"
34- tag_name : v${{ steps.cz.outputs.version }}
35- env :
36- GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
16+ black :
17+ uses : prosegrinder/.github/.github/workflows/poetry-black.yaml@main
18+
19+ pylint :
20+ uses : prosegrinder/.github/.github/workflows/poetry-pylint.yaml@main
21+
22+ mypy :
23+ uses : prosegrinder/.github/.github/workflows/poetry-mypy.yaml@main
24+
25+ bandit :
26+ uses : prosegrinder/.github/.github/workflows/poetry-bandit.yaml@main
27+
28+ test :
29+ needs :
30+ - pylint
31+ - black
32+ - mypy
33+ - bandit
34+ uses : prosegrinder/.github/.github/workflows/poetry-test.yaml@main
35+
36+ release :
37+ needs : test
38+ if : ${{ !startsWith(github.event.head_commit.message, 'bump:') }}
39+ # Don't run 'bump:'
40+ permissions :
41+ contents : write
42+ uses : prosegrinder/.github/.github/workflows/poetry-release.yaml@main
43+ secrets :
44+ VERSION_BUMP_TAG_TOKEN : " ${{ secrets.VERSION_BUMP_TAG_TOKEN }}"
0 commit comments