1
- name : Build and deploy snapshot
1
+ name : Build and Deploy Snapshot
2
2
on :
3
3
push :
4
4
branches :
5
5
- 5.3.x
6
+ permissions :
7
+ actions : write
6
8
concurrency :
7
9
group : ${{ github.workflow }}-${{ github.ref }}
8
10
jobs :
9
11
build-and-deploy-snapshot :
10
- if : ${{ github.repository == 'spring-projects/spring-framework' }}
11
- name : Build and deploy snapshot
12
+ name : Build and Deploy Snapshot
12
13
runs-on : ubuntu-latest
14
+ if : ${{ github.repository == 'spring-projects/spring-framework' }}
13
15
steps :
14
- - name : Set up Java
15
- uses : actions/setup-java@v4
16
- with :
17
- distribution : ' liberica'
18
- java-version : 8
19
- - name : Check out code
16
+ - name : Check Out Code
20
17
uses : actions/checkout@v4
21
- - name : Set up Gradle
22
- uses : gradle/actions/setup-gradle@417ae3ccd767c252f5661f1ace9f835f9654f2b5
18
+ - name : Build and Publish
19
+ id : build-and-publish
20
+ uses : ./.github/actions/build
23
21
with :
24
- cache-read-only : false
25
- - name : Configure Gradle properties
26
- shell : bash
27
- run : |
28
- mkdir -p $HOME/.gradle
29
- echo 'systemProp.user.name=spring-builds+github' >> $HOME/.gradle/gradle.properties
30
- echo 'systemProp.org.gradle.internal.launcher.welcomeMessageEnabled=false' >> $HOME/.gradle/gradle.properties
31
- echo 'org.gradle.daemon=false' >> $HOME/.gradle/gradle.properties
32
- echo 'org.gradle.daemon=4' >> $HOME/.gradle/gradle.properties
33
- - name : Build and publish
34
- id : build
35
- env :
36
- CI : ' true'
37
- GRADLE_ENTERPRISE_URL : ' https://ge.spring.io'
38
- DEVELOCITY_ACCESS_KEY : ${{ secrets.GRADLE_ENTERPRISE_SECRET_ACCESS_KEY }}
39
- run : ./gradlew -PdeploymentRepository=$(pwd)/deployment-repository build publishAllPublicationsToDeploymentRepository
22
+ develocity-access-key : ${{ secrets.GRADLE_ENTERPRISE_SECRET_ACCESS_KEY }}
23
+ publish : true
40
24
- name : Deploy
41
-
25
+ uses : spring-io/artifactory-deploy-action@26bbe925a75f4f863e1e529e85be2d0093cac116 # v0.0.1
42
26
with :
43
27
uri : ' https://repo.spring.io'
44
28
username : ${{ secrets.ARTIFACTORY_USERNAME }}
45
29
password : ${{ secrets.ARTIFACTORY_PASSWORD }}
46
- build-name : ${{ format( 'spring-framework-{0}', github.ref_name)}}
30
+ build-name : ' spring-framework-5.3.x '
47
31
repository : ' libs-snapshot-local'
48
32
folder : ' deployment-repository'
49
33
signing-key : ${{ secrets.GPG_PRIVATE_KEY }}
@@ -53,11 +37,24 @@ jobs:
53
37
/**/spring-*-docs.zip::zip.type=docs
54
38
/**/spring-*-dist.zip::zip.type=dist
55
39
/**/spring-*-schema.zip::zip.type=schema
56
- - name : Send notification
40
+ - name : Send Notification
57
41
uses : ./.github/actions/send-notification
58
42
if : always()
59
43
with :
60
44
webhook-url : ${{ secrets.GOOGLE_CHAT_WEBHOOK_URL }}
61
45
status : ${{ job.status }}
62
- build-scan-url : ${{ steps.build.outputs.build-scan-url }}
63
- run-name : ${{ format('{0} | Linux | Java 8', github.ref_name) }}
46
+ build-scan-url : ${{ steps.build-and-publish.outputs.build-scan-url }}
47
+ run-name : ${{ format('{0} | Linux | Java 8', github.ref_name) }}
48
+ outputs :
49
+ version : ${{ steps.build-and-publish.outputs.version }}
50
+ verify :
51
+ name : Verify
52
+ needs : build-and-deploy-snapshot
53
+ uses : ./.github/workflows/verify.yml
54
+ secrets :
55
+ google-chat-webhook-url : ${{ secrets.GOOGLE_CHAT_WEBHOOK_URL }}
56
+ repository-password : ${{ secrets.ARTIFACTORY_PASSWORD }}
57
+ repository-username : ${{ secrets.ARTIFACTORY_USERNAME }}
58
+ token : ${{ secrets.GH_ACTIONS_REPO_TOKEN }}
59
+ with :
60
+ version : ${{ needs.build-and-deploy-snapshot.outputs.version }}
0 commit comments