File tree Expand file tree Collapse file tree 2 files changed +36
-28
lines changed
Expand file tree Collapse file tree 2 files changed +36
-28
lines changed Original file line number Diff line number Diff line change @@ -2,37 +2,9 @@ name: Maven Publish
22
33on :
44 workflow_dispatch :
5- inputs :
6- libraryVersion :
7- description : ' Library Version'
8- required : true
9- default : ' '
10- packageVersion :
11- description : ' Package Version'
12- required : true
13- default : ' '
145
156jobs :
16- update-version :
17- runs-on : ubuntu-latest
18- steps :
19- - name : Checkout code
20- uses : actions/checkout@v2
21-
22- - name : Update Version
23- run : |
24- sed -i '/VERSION=/!b;cVERSION=\"v${{ github.event.inputs.libraryVersion }}";' ./download-libs.sh
25- - name : Commit, Tag and Push
26- run : |
27- git add ./download-libs.sh
28- git config user.name github-actions
29- git config user.email [email protected] 30- git commit -m "updated version" | exit 0
31- git tag ${{ github.event.inputs.packageVersion }}
32- git push & git push --tags
33-
347 publish :
35- needs : update-version
368 runs-on : ubuntu-latest
379 steps :
3810 - uses : actions/checkout@v2
Original file line number Diff line number Diff line change 1+ name : Update version
2+
3+ on :
4+ workflow_dispatch :
5+ inputs :
6+ libraryVersion :
7+ description : ' Library Version'
8+ required : true
9+ default : ' '
10+ packageVersion :
11+ description : ' Package Version'
12+ required : true
13+ default : ' '
14+
15+ jobs :
16+ update-version :
17+ runs-on : ubuntu-latest
18+ steps :
19+ - name : Checkout code
20+ uses : actions/checkout@v2
21+
22+ - name : Create new branch
23+ run : git checkout -b release/${{ github.event.inputs.packageVersion }}
24+
25+ - name : Update Version
26+ run : |
27+ sed -i '/VERSION=/!b;cVERSION=\"v${{ github.event.inputs.libraryVersion }}";' ./download-libs.sh
28+ - name : Commit, Tag and Push
29+ run : |
30+ git add ./download-libs.sh
31+ git config user.name github-actions
32+ git config user.email [email protected] 33+ git commit -m "updated version" | exit 0
34+ git tag ${{ github.event.inputs.packageVersion }}
35+ git push --set-upstream origin release/${{ github.event.inputs.packageVersion }}
36+ git push --tags
You can’t perform that action at this time.
0 commit comments