Skip to content

Commit dad887e

Browse files
committed
just debugging the workflow
1 parent a8e11b9 commit dad887e

File tree

3 files changed

+36
-37
lines changed

3 files changed

+36
-37
lines changed

.github/workflows/ci-release.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
name: Release Publisher
1+
name: 'Publish (Java): RELEASE'
22
on:
33
push:
44
tags:
@@ -13,7 +13,7 @@ jobs:
1313
swift_version: ['6.1.3']
1414
os_version: ['jammy']
1515
jdk_vendor: ['corretto']
16-
java: ['25']
16+
jdk_version: [ 24, 17 ]
1717
container:
1818
image: ${{ (contains(matrix.swift_version, 'nightly') && 'swiftlang/swift') || 'swift' }}:${{ matrix.swift_version }}-${{ matrix.os_version }}
1919
steps:

.github/workflows/ci-snapshot.yml

Lines changed: 26 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,31 @@
1-
name: Snapshot Publisher
1+
name: 'Publish (Java): SNAPSHOT'
2+
# on:
3+
# push:
4+
# branches: [ main ]
5+
# tags-ignore:
6+
# - "[0-9]+.[0-9]+.[0-9]+(-[0-9a-z]+)?"
7+
# paths-ignore:
8+
# - 'docs/**'
9+
# - 'scripts/**'
10+
# - '.github/pull_request_template.md'
11+
# - '.gitignore'
12+
# - 'gradlew'
13+
# - 'gradlew.bat'
14+
# - '**.adoc'
15+
# - '*.txt'
216
on:
3-
push:
4-
branches: [ main ]
5-
tags-ignore:
6-
- "[0-9]+.[0-9]+.[0-9]+(-[0-9a-z]+)?"
7-
paths-ignore:
8-
- 'docs/**'
9-
- 'scripts/**'
10-
- '.github/pull_request_template.md'
11-
- '.gitignore'
12-
- 'gradlew'
13-
- 'gradlew.bat'
14-
- '**.adoc'
15-
- '*.txt'
17+
pull_request:
18+
types: [opened, reopened, synchronize]
1619
jobs:
1720
build:
18-
name: Release JDK (${{ matrix.os_version }} swift:${{ matrix.swift_version }} jdk:${{matrix.jdk_vendor}})
21+
name: Publish Java libs (${{ matrix.os_version }} swift:${{ matrix.swift_version }} jdk:${{ matrix.jdk_vendor }})
1922
runs-on: ubuntu-latest
2023
strategy:
2124
fail-fast: false
2225
matrix:
2326
swift_version: ['6.1.3']
2427
os_version: ['jammy']
2528
jdk_vendor: ['corretto']
26-
java: ['25']
2729
container:
2830
image: ${{ (contains(matrix.swift_version, 'nightly') && 'swiftlang/swift') || 'swift' }}:${{ matrix.swift_version }}-${{ matrix.os_version }}
2931
steps:
@@ -32,55 +34,45 @@ jobs:
3234
run: if [[ $(cat gradle.properties | grep version= | sed 's/^version=//') =~ .*-SNAPSHOT ]]; then exit 1; else exit 0; fi
3335
- name: Prepare CI Environment
3436
uses: ./.github/actions/prepare_env
35-
- name: Set up jdk:${{matrix.jdk_vendor}} ${{matrix.java}}
36-
uses: actions/setup-java@v5
37-
with:
38-
java-version: ${{ matrix.java }}
39-
distribution: ${{ matrix.jdk_vendor }}
40-
cache: 'gradle'
41-
- name: Print JDK Version
42-
run: java -version
4337
- name: Make gradlew Executable
4438
run: chmod +x gradlew
4539
- name: Clean Gradle project
4640
run: ./gradlew --parallel clean
47-
- name: Build with Gradle
41+
# TODO: run tests here
42+
- name: Publish with Gradle
4843
env:
4944
ORG_GRADLE_PROJECT_signingKey: ${{ secrets.ORG_GRADLE_PROJECT_SIGNINGKEY }}
5045
ORG_GRADLE_PROJECT_signingPassword: ${{ secrets.ORG_GRADLE_PROJECT_SIGNINGPASSWORD }}
5146
SONATYPE_USER: ${{ secrets.SONATYPE_USER }}
5247
SONATYPE_TOKEN: ${{ secrets.SONATYPE_TOKEN }}
5348
run: |
54-
FIRST_GRADLE_TARGETS=" check"
55-
SECOND_GRADLE_TARGETS=" publish"
56-
57-
# Execute the gradlew command to publish the build
58-
sudo -E env "PATH=$PATH" bash -c "ulimit -l 65536 && ulimit -a && ./gradlew --no-daemon --parallel$FIRST_GRADLE_TARGETS && ./gradlew --no-daemon --no-parallel$SECOND_GRADLE_TARGETS"
49+
# Execute the gradle command to publish the project
50+
./gradlew --no-daemon --no-parallel publish
5951
- name: Publish Test Results
6052
if: always()
6153
uses: scacap/action-surefire-report@5609ce4db72c09db044803b344a8968fd1f315da
6254
with:
6355
github_token: ${{ secrets.GITHUB_TOKEN }}
6456
report_paths: '**/build/test-results/test/TEST-*.xml'
65-
check_name: Test Report JDK ${{ matrix.java }}
57+
check_name: Test Report
6658
- name: Publish Checkstyle Report
6759
if: always()
6860
uses: jwgmeligmeyling/checkstyle-github-action@50292990e18466f2c5d95d04ff5fab931254fa5f
6961
with:
70-
name: Checkstyle Report JDK ${{ matrix.java }}
62+
name: Checkstyle Report
7163
path: '**/build/reports/checkstyle/*.xml'
7264
token: ${{ secrets.GITHUB_TOKEN }}
7365
- name: Publish PMD Report
7466
if: always()
7567
uses: jwgmeligmeyling/pmd-github-action@322e346bd76a0757c4d54ff9209e245965aa066d
7668
with:
77-
name: PMD Report JDK ${{ matrix.java }}
69+
name: PMD Report
7870
path: '**/build/reports/pmd/*.xml'
7971
token: ${{ secrets.GITHUB_TOKEN }}
8072
- name: Publish SpotBugs Report
8173
if: always()
8274
uses: jwgmeligmeyling/spotbugs-github-action@b8e2c3523acb34c87f14e18cbcd2d87db8c8584e
8375
with:
84-
name: SpotBugs Report JDK ${{ matrix.java }}
76+
name: SpotBugs Report
8577
path: '**/build/reports/spotbugs/*.xml'
8678
token: ${{ secrets.GITHUB_TOKEN }}

.github/workflows/pull_request.yml

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ jobs:
3030
swift_version: ['6.1.3']
3131
os_version: ['jammy']
3232
jdk_vendor: ['corretto']
33+
jdk_version: [ 24, 17 ]
3334
steps:
3435
- uses: actions/checkout@v4
3536
- name: Prepare CI Environment
@@ -48,6 +49,7 @@ jobs:
4849
swift_version: ['6.1.3', 'nightly']
4950
os_version: ['jammy']
5051
jdk_vendor: ['corretto']
52+
jdk_version: [ 24, 17 ]
5153
container:
5254
image: ${{ (contains(matrix.swift_version, 'nightly') && 'swiftlang/swift') || 'swift' }}:${{ matrix.swift_version }}-${{ matrix.os_version }}
5355
env:
@@ -74,6 +76,7 @@ jobs:
7476
swift_version: ['6.2.0']
7577
os_version: ['macos']
7678
jdk_vendor: ['corretto']
79+
jdk_version: [ 24, 17 ]
7780
env:
7881
SWIFT_JAVA_VERBOSE: true
7982
steps:
@@ -98,6 +101,7 @@ jobs:
98101
swift_version: ['6.2.0']
99102
os_version: ['jammy']
100103
jdk_vendor: ['corretto']
104+
jdk_version: [ 24, 17 ]
101105
container:
102106
image: ${{ (contains(matrix.swift_version, 'nightly') && 'swiftlang/swift') || 'swift' }}:${{ matrix.swift_version }}-${{ matrix.os_version }}
103107
env:
@@ -140,6 +144,7 @@ jobs:
140144
swift_version: ['6.2.0']
141145
os_version: ['macos']
142146
jdk_vendor: ['corretto']
147+
jdk_version: [ 24, 17 ]
143148
env:
144149
SWIFT_JAVA_VERBOSE: true
145150
steps:
@@ -160,6 +165,7 @@ jobs:
160165
swift_version: ['6.1.3', 'nightly']
161166
os_version: ['jammy']
162167
jdk_vendor: ['corretto']
168+
jdk_version: [ 24, 17 ]
163169
sample_app: [ # TODO: use a reusable-workflow to generate those names
164170
'JavaDependencySampleApp',
165171
'JavaKitSampleApp',
@@ -180,14 +186,15 @@ jobs:
180186

181187

182188
verify-samples-macos:
183-
name: Sample ${{ matrix.sample_app }} (${{ matrix.os_version }} swift:${{ matrix.swift_version }} jdk:${{matrix.jdk_vendor}})
189+
name: Sample ${{ matrix.sample_app }} (${{ matrix.os_version }} swift:${{ matrix.swift_version }} jdk:${{ matrix.jdk_version }}-${{matrix.jdk_vendor}}
184190
runs-on: [self-hosted, macos, sequoia, ARM64]
185191
strategy:
186192
fail-fast: false
187193
matrix:
188194
swift_version: ['6.2.0'] # no nightly testing on macOS
189195
os_version: ['macos']
190196
jdk_vendor: ['corretto']
197+
jdk_version: [ 24, 17 ]
191198
sample_app: [ # TODO: use a reusable-workflow to generate those names
192199
'JavaDependencySampleApp',
193200
'JavaKitSampleApp',

0 commit comments

Comments
 (0)