@@ -36,25 +36,31 @@ jobs:
36
36
- name : Install JDK
37
37
run : " bash -xc 'JDK_VENDOR=${{ matrix.jdk_vendor }} ./docker/install_jdk.sh'"
38
38
# TODO: not using setup-java since incompatible with the swiftlang/swift base image
39
- # - uses: actions/setup-java@v4
40
- # with:
41
- # distribution: 'zulu'
42
- # java-version: '22'
43
- # cache: 'gradle'
44
- - name : Install Nightly Swift
39
+ - name : Install Untested Nightly Swift
45
40
run : " bash -xc './docker/install_untested_nightly_swift.sh'"
46
- # Cache .m2/repository
41
+ # setup caches
47
42
- name : Cache local Gradle repository
48
43
uses : actions/cache@v4
49
44
continue-on-error : true
50
45
with :
51
- path : ~/.gradle/caches
52
- key : ${{ runner.os }}-gradle-cache-${{ hashFiles('**/build.gradle') }}-${{ hashFiles('**/build.gradle.kts') }}
46
+ path : |
47
+ /root/.gradle/caches
48
+ /root/.gradle/wrapper
49
+ key : ${{ runner.os }}-gradle-${{ hashFiles('*/*.gradle*', 'settings.gradle') }}
53
50
restore-keys : |
54
- ${{ runner.os }}-gradle-cache
55
51
${{ runner.os }}-gradle-
52
+ - name : Cache local SwiftPM repository
53
+ uses : actions/cache@v4
54
+ continue-on-error : true
55
+ with :
56
+ path : /__w/swift-java/swift-java/.build/checkouts
57
+ key : ${{ runner.os }}-swiftpm-cache-${{ hashFiles('Package.swift') }}
58
+ restore-keys : |
59
+ ${{ runner.os }}-swiftpm-cache
60
+ ${{ runner.os }}-swiftpm-
61
+ # run the actual build
56
62
- name : Gradle build
57
- run : ./gradlew build --info --no-daemon
63
+ run : ./gradlew update --info --no-daemon
58
64
59
65
test-swift :
60
66
name : Swift tests (swift:${{ matrix.swift_version }} jdk:${{matrix.jdk_vendor}} os:${{ matrix.os_version }})
75
81
run : apt-get -qq update && apt-get -qq install -y make curl wget
76
82
- name : Install JDK
77
83
run : " bash -xc 'JDK_VENDOR=${{ matrix.jdk_vendor }} ./docker/install_jdk.sh'"
78
- - name : Install Nightly Swift
84
+ - name : Install Untested Nightly Swift
79
85
run : " bash -xc './docker/install_untested_nightly_swift.sh'"
86
+ # setup caches
87
+ - name : Cache local Gradle repository
88
+ uses : actions/cache@v4
89
+ continue-on-error : true
90
+ with :
91
+ path : |
92
+ /root/.gradle/caches
93
+ /root/.gradle/wrapper
94
+ key : ${{ runner.os }}-gradle-${{ hashFiles('*/*.gradle*', 'settings.gradle') }}
95
+ restore-keys : |
96
+ ${{ runner.os }}-gradle-
97
+ - name : Cache local SwiftPM repository
98
+ uses : actions/cache@v4
99
+ continue-on-error : true
100
+ with :
101
+ path : /__w/swift-java/swift-java/.build/checkouts
102
+ key : ${{ runner.os }}-swiftpm-cache-${{ hashFiles('Package.swift') }}
103
+ restore-keys : |
104
+ ${{ runner.os }}-swiftpm-cache
105
+ ${{ runner.os }}-swiftpm-
106
+ # run the actual build
80
107
- name : Generate sources (make) (Temporary)
81
108
# TODO: this should be triggered by the respective builds
82
109
run : " make jextract-run"
0 commit comments