File tree Expand file tree Collapse file tree 2 files changed +6
-5
lines changed
Expand file tree Collapse file tree 2 files changed +6
-5
lines changed Original file line number Diff line number Diff line change @@ -3,7 +3,7 @@ name: Build
33on :
44 push :
55 pull_request :
6- branches : [ master ]
6+ branches : [ ' master','release/5.0.0-SNAPSHOT' ]
77
88jobs :
99 build-maven :
Original file line number Diff line number Diff line change @@ -2,12 +2,12 @@ name: Package/Deploy
22
33on :
44 workflow_run :
5- branches : [ master ]
6- workflows : ["Build"]
5+ branches : [ ' master','release/5.0.0-SNAPSHOT' ]
6+ workflows : ["Build","Release" ]
77 types : [completed]
88jobs :
99 package-deploy-maven :
10- if : ${{ github.event.workflow_run.conclusion == 'success' }}
10+ if : ${{ github.event.workflow_run.conclusion == 'success' && github.event.workflow_run.event=='push' }}
1111 runs-on : ' ubuntu-latest'
1212 steps :
1313 - name : Print github context
@@ -31,10 +31,11 @@ jobs:
3131 with :
3232 fetch-depth : 0
3333 submodules : recursive
34+ ref : ${{ github.event.workflow_run.head_branch }}
3435 - name : Set up Java for publishing to Maven Central Repository OSS
3536 uses : actions/setup-java@v4
3637 with :
37- java-version : ' 8 '
38+ java-version : ${{ github.event.workflow_run.head_branch == 'release/5.0.0-SNAPSHOT' && '11' || '8'}}
3839 distribution : ' temurin'
3940 server-id : ossrh
4041 server-username : MAVEN_USERNAME
You can’t perform that action at this time.
0 commit comments