Skip to content

Commit 1f7109b

Browse files
authored
better control of CI testing
more fine grained. No CI on draft PR, but listen for ready_to_review event
1 parent ed847f8 commit 1f7109b

File tree

1 file changed

+14
-4
lines changed

1 file changed

+14
-4
lines changed

.github/workflows/maven.yml

Lines changed: 14 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,14 +12,24 @@ on:
1212
push:
1313
branches: [ "master" ]
1414
pull_request:
15-
branches: [ "master" , "develop"]
15+
branches: [ "master", "develop" ]
16+
types: [opened, synchronize, reopened, ready_for_review]
17+
workflow_dispatch:
1618

1719
jobs:
1820
build:
1921
if: |
20-
(github.event_name == 'push') ||
21-
(github.event.pull_request.base.ref == 'master') ||
22-
(github.event.pull_request.base.ref == 'develop' && github.event.action == 'closed')
22+
github.event_name == 'push' ||
23+
(
24+
github.event_name == 'pull_request' &&
25+
(github.event.pull_request.base.ref == 'master' || github.event.pull_request.base.ref == 'develop') &&
26+
!github.event.pull_request.draft
27+
) ||
28+
(
29+
github.event_name == 'pull_request' &&
30+
github.event.action == 'closed' &&
31+
github.event.pull_request.base.ref == 'develop'
32+
)
2333
2434
strategy:
2535
matrix:

0 commit comments

Comments
 (0)