File tree Expand file tree Collapse file tree 2 files changed +5
-4
lines changed
Expand file tree Collapse file tree 2 files changed +5
-4
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/7.0.0-SNAPSHOT' ]
77
88jobs :
99 build-maven :
Original file line number Diff line number Diff line change @@ -3,13 +3,13 @@ name: Package/Deploy
33on :
44 workflow_dispatch :
55 workflow_run :
6- branches : [ master ]
6+ branches : [ ' master','release/7.0.0-SNAPSHOT' ]
77 workflows : ["Build","Release"]
88 types : [completed]
99
1010jobs :
1111 deploy-maven :
12- if : ${{ github.event.workflow_run.conclusion == 'success' }}
12+ if : ${{ github.event.workflow_run.conclusion == 'success' && github.event.workflow_run.event=='push' }}
1313 runs-on : ' ubuntu-latest'
1414 steps :
1515 - name : Print github context
@@ -20,10 +20,11 @@ jobs:
2020 with :
2121 fetch-depth : 0
2222 submodules : recursive
23+ ref : ${{ github.event.workflow_run.head_branch }}
2324 - name : Set up Java for publishing to Maven Central Repository OSS
2425 uses : actions/setup-java@v4
2526 with :
26- java-version : ' 8 '
27+ java-version : ${{ github.event.workflow_run.head_branch == 'release/7.0.0-SNAPSHOT' && '17' || '8'}}
2728 distribution : ' temurin'
2829 server-id : ossrh
2930 server-username : MAVEN_USERNAME
You can’t perform that action at this time.
0 commit comments