From 166362334ba7799871419f493c6fb5f5d9fb2e95 Mon Sep 17 00:00:00 2001 From: Speiger Date: Thu, 7 Apr 2022 20:26:53 +0200 Subject: [PATCH] Added gradle now uses the java version it runs on. --- .github/workflows/build_validator.yml | 2 -- build.gradle | 4 ++-- gradle.properties | 4 +--- 3 files changed, 3 insertions(+), 7 deletions(-) diff --git a/.github/workflows/build_validator.yml b/.github/workflows/build_validator.yml index 288d73f..e6ea6a0 100644 --- a/.github/workflows/build_validator.yml +++ b/.github/workflows/build_validator.yml @@ -35,7 +35,5 @@ jobs: run: chmod +x ./gradlew - name: Generate SourceCode with Gradle run: ./gradlew generateGithubSource - - name: Setting Java Version - run: echo pcJavaVersion=${{matrix.jdk}} > ./local.properties - name: Build with Gradle run: ./gradlew build diff --git a/build.gradle b/build.gradle index 32892bb..da5dc0c 100644 --- a/build.gradle +++ b/build.gradle @@ -20,9 +20,9 @@ repositories { archivesBaseName = 'Primitive Collections' version = '0.5.4'; -sourceCompatibility = targetCompatibility = compileJava.sourceCompatibility = compileJava.targetCompatibility = JavaLanguageVersion.of(pcJavaVersion) +sourceCompatibility = targetCompatibility = compileJava.sourceCompatibility = compileJava.targetCompatibility = JavaVersion.current(); -System.out.println("Java Version: "+pcJavaVersion) +System.out.println("Java Version: "+compileJava.sourceCompatibility) javadoc { options.tags = [ "implSpec", "note" ] diff --git a/gradle.properties b/gradle.properties index 76ab5cd..659b74c 100644 --- a/gradle.properties +++ b/gradle.properties @@ -1,3 +1 @@ -org.gradle.jvmargs=-Xmx3G - -pcJavaVersion=8 \ No newline at end of file +org.gradle.jvmargs=-Xmx3G \ No newline at end of file