Skip to content

Commit

Permalink
All projects now on java 17
Browse files Browse the repository at this point in the history
  • Loading branch information
Alex McAusland committed Sep 6, 2023
1 parent de6ef74 commit 7b007b2
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 18 deletions.
6 changes: 1 addition & 5 deletions .github/workflows/check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,11 +19,7 @@ jobs:
uses: actions/setup-java@v3
with:
distribution: 'temurin'
java-version: |
11
17
java-version: 17
cache: 'gradle'
- name: Set JDK 11 location
run: echo "JDK_11=$JAVA_HOME_11_X64" >> "$GITHUB_ENV"
- name: Build
run: (cd cftlib;./gradlew -PtestSpringBootVersion=${{inputs.test_spring_boot_version}} check -i)
8 changes: 2 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ Improved local development and robust automated tests when working with CCD:

## Prerequisites

- Java 11
- Java 17
- Gradle 7.6
- Docker
- [Azure CLI](https://docs.microsoft.com/en-us/cli/azure/install-azure-cli) (when using automated AAT secret management)
Expand Down Expand Up @@ -296,11 +296,7 @@ The cftlib maintains a log file per service in your build directory; `build/cftl

## Building the cftlib

The Cftlib build uses both JDK 17 & 11 (for common components still on Java 11).

Environment variables JAVA_HOME must be set to JDK 17 and JDK_11 must point to your Java 11 JDK location.

TODO: Remove the use of JDK 11 once all common components are on Java 17.
The Cftlib build requires JDK 17.

## How the cftlib works

Expand Down
4 changes: 0 additions & 4 deletions cftlib/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,6 @@ project.file('../projects').listFiles().each { dir ->
inputs.property('sha', ['git', 'submodule', 'status', dir].execute().text)
outputs.dir "${project.repositories.mavenLocal().url}/com/github/hmcts/rse-cft-lib/${dir.name}"
executable './gradlew'
// Jitpack will not have this defined; JDK 11 is used by default.
if (System.env.JDK_11) {
args "-Dorg.gradle.java.home=${System.env.JDK_11}"
}
args '-i', '-I', project.file('init.gradle').path, 'publishToMavenLocal'
workingDir dir
}
Expand Down
5 changes: 2 additions & 3 deletions jitpack.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
# The default jitpack openjdk 11 hits a compiler bug for access management.
before_install:
- sdk install java 11.0.14-ms
- sdk use java 11.0.14-ms
- sdk install java 17.0.8.1-ms
- sdk use java 17.0.8.1-ms
install:
- (cd cftlib;./gradlew -is :publish)

0 comments on commit 7b007b2

Please sign in to comment.