File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -3,9 +3,34 @@ name: Publish
33on : push
44
55jobs :
6+ vars :
7+ name : Get Variables
8+ runs-on : ubuntu-22.04
9+ outputs :
10+ version : ${{steps.version.outputs.version}}
11+
12+ steps :
13+ - name : Checkout
14+ uses : actions/checkout@v6
15+ with :
16+ fetch-depth : 150
17+ fetch-tags : " true"
18+
19+ - name : Fetch Tags
20+ run : git fetch --tags
21+
22+ - name : Version
23+ id : version
24+ uses : paulhatch/semantic-version@v5.4.0
25+ with :
26+ version_format : " ${major}.${minor}.${patch}"
27+ search_commit_body : true
28+ bump_each_commit : true
29+
630 publish :
731 name : Publish Code as Github Package - ${{ inputs.version }}
832 runs-on : ubuntu-22.04
33+ needs : vars
934 steps :
1035 - name : Checkout
1136 uses : actions/checkout@v6
2247 - name : Publish
2348 run : ./gradlew :publish
2449 env :
25- VERSION : ${{ inputs .version }}
50+ VERSION : ${{ needs.vars.outputs .version }}
2651 GITHUB_ACTOR : ${{ secrets.GITHUB_ACTOR }}
2752 GITHUB_TOKEN : ${{ secrets.GITHUB_TOKEN }}
You can’t perform that action at this time.
0 commit comments