File tree Expand file tree Collapse file tree 1 file changed +8
-2
lines changed
Expand file tree Collapse file tree 1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change 1919 - name : Checkout
2020 uses : actions/checkout@v3
2121 with :
22- ref : master
22+ fetch-depth : 0
23+ - name : Set env
24+ run : |
25+ echo "RELEASE_TAG=${GITHUB_REF#refs/*/}" >> $GITHUB_ENV
26+ echo "BRANCH=$(git branch -r --contains ${GITHUB_REF} | grep -v HEAD | sed -n 's/ *origin\/\(.*\)/\1/p')" >> $GITHUB_ENV
2327 - name : Set up Python
2428 uses : actions/setup-python@v4
2529 with :
3034 pip install setuptools wheel twine
3135 - name : get infos from Tag
3236 run : |
33- if [[ $GITHUB_REF =~ (([0-9]+)\.([0-9]+)\.([0-9]+))([-./]dev([0-9]+))? ]]
37+ if [[ $RELEASE_TAG =~ (([0-9]+)\.([0-9]+)\.([0-9]+))([-./]dev([0-9]+))? ]]
3438 then
3539 echo "VERSION=${BASH_REMATCH[0]}" >> $GITHUB_ENV
3640 echo "VERSION_MAJOR=${BASH_REMATCH[2]}" >> $GITHUB_ENV
7276 - name : commit new version-number
7377 uses : stefanzweifel/git-auto-commit-action@v4
7478 with :
79+ branch : ${{ env.BRANCH }}
80+ create_branch : true
7581 commit_message : " increment version after release"
You can’t perform that action at this time.
0 commit comments