Skip to content

Commit c8bc07b

Browse files
committed
Play with cancelling + introduce schedule
1 parent 8c967bd commit c8bc07b

File tree

1 file changed

+11
-7
lines changed

1 file changed

+11
-7
lines changed

.github/workflows/eric-continuous-integration.yml

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,17 +6,19 @@ on:
66
- 'main'
77
- '[0-9].[0-9].x'
88
- 'workflows-rework-main'
9+
schedule:
10+
- cron: '30 11 * * 1-5' # 12:30 PM CET / 6:30 AM EST
11+
12+
concurrency:
13+
group: ${{ github.workflow }}-${{ github.ref }}
14+
cancel-in-progress: true
915

1016
jobs:
1117
build-all:
1218
name: Build all modules
1319
runs-on: ubuntu-latest
1420
if: ${{ github.repository_owner == 'spring-projects' }}
1521
steps:
16-
- name: Print type
17-
run: |
18-
echo "Type ${{ github.event_name }}"
19-
2022
- name: Checkout source code
2123
uses: actions/checkout@v4
2224

@@ -28,6 +30,7 @@ jobs:
2830
cache: 'maven'
2931

3032
- name: Setup Maven Build-Cache (~/.m2/build-cache)
33+
if: ${{ github.event_name != 'schedule' }}
3134
uses: actions/cache@v4
3235
with:
3336
path: ~/.m2/build-cache
@@ -77,6 +80,7 @@ jobs:
7780

7881
- name: Setup Maven Build-Cache (~/.m2/build-cache)
7982
uses: actions/cache@v4
83+
if: ${{ github.event_name != 'schedule' }}
8084
with:
8185
path: ~/.m2/build-cache
8286
key: build-cache-${{ runner.os }}-ollama-${{ hashFiles('**/pom.xml') }}
@@ -194,11 +198,11 @@ jobs:
194198
-Dfailsafe.rerunFailingTestsCount=3 \
195199
verify
196200
197-
generate-artifacts:
201+
generate-javadocs:
198202
name: Generate and upload javadocs
199203
runs-on: ubuntu-latest
200204
needs: [build-all, test-ollama, test-openai, test-remaining]
201-
if: ${{ github.repository_owner == 'spring-projects' }}
205+
if: ${{ github.repository_owner == 'spring-projects' && github.event_name != 'schedule'}}
202206
steps:
203207
- name: Checkout source code
204208
uses: actions/checkout@v4
@@ -249,7 +253,7 @@ jobs:
249253
name: Deploy to Artifactory
250254
runs-on: ubuntu-latest
251255
needs: [build-all, test-ollama, test-openai, test-remaining]
252-
if: ${{ github.repository_owner == 'spring-projects' }}
256+
if: ${{ github.repository_owner == 'spring-projects' && github.event_name != 'schedule' }}
253257
steps:
254258
- name: Checkout source code
255259
uses: actions/checkout@v4

0 commit comments

Comments
 (0)