Skip to content

Commit 88f05a1

Browse files
committed
WIP
1 parent 8e09331 commit 88f05a1

File tree

1 file changed

+44
-18
lines changed

1 file changed

+44
-18
lines changed

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

Lines changed: 44 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -111,11 +111,19 @@ jobs:
111111
distribution: 'temurin'
112112
cache: 'maven'
113113

114-
- name: Download Maven repository
114+
- name: Setup Maven Build-Cache (~/.m2/build-cache)
115+
uses: actions/cache@v4
116+
with:
117+
path: ~/.m2/build-cache
118+
key: build-cache-${{ runner.os }}-${{ hashFiles('**/pom.xml') }}
119+
restore-keys: |
120+
build-cache-${{ runner.os }}-
121+
122+
- name: Download Spring-AI Built Artifacts
115123
uses: actions/download-artifact@v4
116124
with:
117-
name: maven-repo
118-
path: ~/.m2/repository
125+
name: build-artifacts
126+
path: ~/.m2/repository/org/springframework/ai
119127

120128
- name: Configure Testcontainers
121129
run: |
@@ -148,11 +156,19 @@ jobs:
148156
distribution: 'temurin'
149157
cache: 'maven'
150158

151-
- name: Download Maven repository
159+
- name: Setup Maven Build-Cache (~/.m2/build-cache)
160+
uses: actions/cache@v4
161+
with:
162+
path: ~/.m2/build-cache
163+
key: build-cache-${{ runner.os }}-${{ hashFiles('**/pom.xml') }}
164+
restore-keys: |
165+
build-cache-${{ runner.os }}-
166+
167+
- name: Download Spring-AI Built Artifacts
152168
uses: actions/download-artifact@v4
153169
with:
154-
name: maven-repo
155-
path: ~/.m2/repository
170+
name: build-artifacts
171+
path: ~/.m2/repository/org/springframework/ai
156172

157173
- name: Configure Testcontainers
158174
run: |
@@ -173,7 +189,7 @@ jobs:
173189
name: Generate documentation artifacts
174190
runs-on: ubuntu-latest
175191
needs: [build-all, test-ollama, test-openai, test-remaining]
176-
if: ${{ (github.ref == 'refs/heads/main' || github.ref == 'refs/heads/1.1.x') && github.repository_owner == 'spring-projects' }}
192+
if: ${{ github.repository_owner == 'spring-projects' }}
177193
steps:
178194
- name: Checkout source code
179195
uses: actions/checkout@v4
@@ -185,11 +201,13 @@ jobs:
185201
distribution: 'temurin'
186202
cache: 'maven'
187203

188-
- name: Download Maven repository
189-
uses: actions/download-artifact@v4
204+
- name: Setup Maven Build-Cache (~/.m2/build-cache)
205+
uses: actions/cache@v4
190206
with:
191-
name: maven-repo
192-
path: ~/.m2/repository
207+
path: ~/.m2/build-cache
208+
key: build-cache-${{ runner.os }}-${{ hashFiles('**/pom.xml') }}
209+
restore-keys: |
210+
build-cache-${{ runner.os }}-
193211
194212
- name: Generate Java docs
195213
run: ./mvnw --batch-mode -ntp javadoc:aggregate
@@ -216,7 +234,7 @@ jobs:
216234
name: Deploy to Artifactory
217235
runs-on: ubuntu-latest
218236
needs: [build-all, test-ollama, test-openai, test-remaining]
219-
if: ${{ (github.ref == 'refs/heads/main' || github.ref == 'refs/heads/1.1.x') && github.repository_owner == 'spring-projects' }}
237+
if: ${{ github.repository_owner == 'spring-projects' }}
220238
steps:
221239
- name: Checkout source code
222240
uses: actions/checkout@v4
@@ -228,24 +246,32 @@ jobs:
228246
distribution: 'temurin'
229247
cache: 'maven'
230248

231-
- name: Download Maven repository
249+
- name: Setup Maven Build-Cache (~/.m2/build-cache)
250+
uses: actions/cache@v4
251+
with:
252+
path: ~/.m2/build-cache
253+
key: build-cache-${{ runner.os }}-${{ hashFiles('**/pom.xml') }}
254+
restore-keys: |
255+
build-cache-${{ runner.os }}-
256+
257+
- name: Download Spring-AI Built Artifacts
232258
uses: actions/download-artifact@v4
233259
with:
234-
name: maven-repo
235-
path: ~/.m2/repository
260+
name: build-artifacts
261+
path: ~/.m2/repository/org/springframework/ai
236262

237263
- name: Deploy to Artifactory
238264
env:
239265
ARTIFACTORY_USERNAME: ${{ secrets.ARTIFACTORY_USERNAME }}
240266
ARTIFACTORY_PASSWORD: ${{ secrets.ARTIFACTORY_PASSWORD }}
241267
run: |
242-
./mvnw -s settings.xml --batch-mode -ntp -DskipTests deploy
268+
./mvnw -s settings.xml --batch-mode -ntp -Dmaven.test.skip -Dmaven.javadoc.skip deploy
243269
244-
deploy-docs:
270+
deploy-docs: #JAVADOCS only, and double management!!?
245271
name: Deploy documentation
246272
runs-on: ubuntu-latest
247273
needs: [generate-artifacts]
248-
if: ${{ (github.ref == 'refs/heads/main' || github.ref == 'refs/heads/1.1.x') && github.repository_owner == 'spring-projects' }}
274+
if: ${{ github.repository_owner == 'spring-projects' }}
249275
steps:
250276
- name: Checkout source code
251277
uses: actions/checkout@v4

0 commit comments

Comments
 (0)