Skip to content

Commit

Permalink
Build with Java 21 and gradle 8.8 (#18)
Browse files Browse the repository at this point in the history
* Build with Java 21 and gradle 8.8

Signed-off-by: Luis Pinto <[email protected]>

* make pTML work

Signed-off-by: Luis Pinto <[email protected]>

* fix signing

Signed-off-by: Luis Pinto <[email protected]>

* remove reference-test CI step

Signed-off-by: Luis Pinto <[email protected]>

---------

Signed-off-by: Luis Pinto <[email protected]>
  • Loading branch information
lu-pinto authored Dec 19, 2024
1 parent 780b7ee commit 5383996
Show file tree
Hide file tree
Showing 30 changed files with 293 additions and 454 deletions.
76 changes: 24 additions & 52 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,35 +28,35 @@ jobs:
timeout-minutes: 30
runs-on: ubuntu-latest
container:
image: tmio/tuweni-build:1.2
image: consensys/tuweni-build:1.3
steps:
- uses: actions/checkout@v4
with:
submodules: true
- name: Set up GPG key
run: gpg --import gradle/tuweni-test.asc
- name: Set up JDK 17
uses: actions/setup-java@v3
- name: Set up JDK 21
uses: actions/setup-java@v4
with:
distribution: temurin
java-version: 17
java-version: 21
cache: gradle
- name: gradle assemble
run: gradle assemble compileTestJava compileIntegrationTestJava -x test -Psignatory.keyId=90010D4396A46BAF -Psigning.gnupg.keyName=90010D4396A46BAF -Psigning.gnupg.executable=gpg
env:
ENABLE_SIGNING: true
- name: Upload source distrib
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: distsrc
path: dist/build/distributions/tuweni-src-*.zip
- name: Upload binary distrib
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: snapshot.zip
path: dist/build/distributions/tuweni-bin-*.zip
- name: Cache classes
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: "**/*.class"
key: ${{ runner.os }}-build-${{ github.sha }}
Expand All @@ -65,27 +65,27 @@ jobs:
runs-on: ubuntu-latest
needs: assemble
container:
image: tmio/tuweni-build:1.2
image: consensys/tuweni-build:1.3
steps:
- uses: actions/checkout@v4
with:
submodules: true
- name: Set up JDK 17
uses: actions/setup-java@v3
- name: Set up JDK 21
uses: actions/setup-java@v4
with:
distribution: temurin
java-version: 17
java-version: 21
cache: gradle
- name: Cache classes
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: "**/*.class"
key: ${{ runner.os }}-build-${{ github.sha }}
- name: gradle test
run: gradle test
- name: Archive Junit Report
if: always()
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: junit-report
path: '**/build/reports/tests/**'
Expand All @@ -98,7 +98,7 @@ jobs:
needs: assemble
steps:
- name: Download distsrc
uses: actions/download-artifact@v3
uses: actions/download-artifact@v4
id: download
with:
name: distsrc
Expand All @@ -110,10 +110,10 @@ jobs:
run: Expand-Archive -Force -Path tuweni-src-*.zip -DestinationPath distunzipped
- name: Rename folder
run: mv distunzipped/tuweni-src-* distunzipped/tuweni
- name: Set up JDK 17
uses: actions/setup-java@v3
- name: Set up JDK 21
uses: actions/setup-java@v4
with:
java-version: 17
java-version: 21
distribution: temurin
cache: gradle
- name: Build from source
Expand All @@ -127,56 +127,28 @@ jobs:
runs-on: ubuntu-latest
needs: assemble
container:
image: tmio/tuweni-build:1.2
image: consensys/tuweni-build:1.3
steps:
- uses: actions/checkout@v4
with:
submodules: true
- name: Set up JDK 17
uses: actions/setup-java@v3
- name: Set up JDK 21
uses: actions/setup-java@v4
with:
distribution: temurin
java-version: 17
java-version: 21
cache: gradle
- name: Cache classes
uses: actions/cache@v3
uses: actions/cache@v4
with:
path: "**/*.class"
key: ${{ runner.os }}-build-${{ github.sha }}
- name: gradle integrationTest
run: gradle compileJava compileKotlin compileIntegrationTestJava compileIntegrationTestKotlin devp2p:integrationTest dist:integrationTest
- name: Archive Junit Report
if: always()
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: junit-report
path: '**/build/reports/tests/**'
retention-days: 5
referenceTests:
timeout-minutes: 30
needs: assemble
runs-on: ubuntu-latest
container:
image: tmio/tuweni-build:1.2
steps:
- uses: actions/checkout@v4
with:
submodules: true
- name: Set up JDK 17
uses: actions/setup-java@v3
with:
distribution: temurin
java-version: 17
cache: gradle
- name: Cache classes
uses: actions/cache@v3
with:
path: "**/*.class"
key: ${{ runner.os }}-build-${{ github.sha }}
- name: Archive Junit Report
if: always()
uses: actions/upload-artifact@v3
with:
name: junit-report
name: integration-junit-report
path: '**/build/reports/tests/**'
retention-days: 5
10 changes: 5 additions & 5 deletions .github/workflows/checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,14 +28,14 @@ jobs:
timeout-minutes: 30
runs-on: ubuntu-latest
container:
image: tmio/tuweni-build:1.2
image: consensys/tuweni-build:1.3
steps:
- uses: actions/checkout@v4
- name: Set up JDK 17
uses: actions/setup-java@v3
- name: Set up JDK 21
uses: actions/setup-java@v4
with:
distribution: temurin
java-version: 17
java-version: 21
cache: gradle
- name: gradle spotlessCheck checkNotice
run: gradle spotlessCheck checkNotice
run: gradle spotlessCheck checkNotice
4 changes: 2 additions & 2 deletions .github/workflows/close-stale.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
stale:
runs-on: ubuntu-latest
steps:
- uses: actions/stale@v8
- uses: actions/stale@v9
with:
repo-token: ${{ secrets.GITHUB_TOKEN }}
stale-pr-message: 'This PR was marked stale due to lack of activity. It will be closed in 14 days.'
Expand All @@ -35,4 +35,4 @@ jobs:
days-before-issue-stale: -1 # Stale label is applied by mark-issues-as-stale.yml
days-before-pr-close: 14
days-before-issue-close: 60
exempt-issue-labels: 'never stale'
exempt-issue-labels: 'never stale'
12 changes: 6 additions & 6 deletions .github/workflows/docs.yml.disable
Original file line number Diff line number Diff line change
Expand Up @@ -30,27 +30,27 @@ jobs:
timeout-minutes: 30
runs-on: ubuntu-latest
container:
image: tmio/tuweni-build:1.2
image: consensys/tuweni-build:1.3
steps:
- uses: actions/checkout@v1
- uses: actions/checkout@v4
with:
submodules: true
- name: Cache Gradle packages
uses: actions/cache@v1
uses: actions/cache@v4
with:
path: ~/.gradle/caches
key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle') }}
restore-keys: ${{ runner.os }}-gradle
- name: Cache Maven Repository
uses: actions/cache@v1
uses: actions/cache@v4
with:
path: ~/.m2
key: ${{ runner.os }}-m2-${{ hashFiles('**/dependency-versions.gradle') }}
restore-keys: ${{ runner.os }}-m2
- name: gradle docs
run: gradle docs
- name: Upload docs
uses: actions/upload-artifact@v2
uses: actions/upload-artifact@v4
with:
name: Docs
path: "build/docs"
path: "build/docs"
4 changes: 2 additions & 2 deletions .github/workflows/license-checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,10 +26,10 @@ jobs:
timeout-minutes: 30
runs-on: ubuntu-latest
container:
image: tmio/tuweni-build:1.2
image: consensys/tuweni-build:1.3
steps:
- uses: actions/checkout@v4
with:
submodules: true
- name: gradle checkLicense
run: gradle checkLicense
run: gradle checkLicense
8 changes: 4 additions & 4 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ jobs:
publish:
runs-on: ubuntu-latest
container:
image: tmio/tuweni-build:1.2
image: consensys/tuweni-build:1.3
permissions:
contents: read
packages: write
Expand All @@ -34,12 +34,12 @@ jobs:
submodules: true
- uses: actions/setup-java@v4
with:
java-version: '17'
java-version: '21'
distribution: 'temurin'
- name: Setup Gradle
uses: gradle/actions/setup-gradle@417ae3ccd767c252f5661f1ace9f835f9654f2b5 # v3.1.0
uses: gradle/actions/setup-gradle@cc4fc85e6b35bafd578d5ffbc76a5518407e1af0 # v4.2.1

- name: Publish package
run: ./gradlew publishAllPublicationsToGitHubPackagesRepository
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
10 changes: 5 additions & 5 deletions .github/workflows/test-windows.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,18 +33,18 @@ jobs:
- uses: actions/checkout@v4
with:
submodules: true
- name: Set up JDK 17
uses: actions/setup-java@v3
- name: Set up JDK 21
uses: actions/setup-java@v4
with:
distribution: temurin
java-version: 17
java-version: 21
cache: gradle
- name: gradle test
run: ./gradlew.bat test
- name: Archive Junit Report
if: always()
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: junit-report
path: '**/build/reports/tests/**'
retention-days: 5
retention-days: 5
Loading

0 comments on commit 5383996

Please sign in to comment.