You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@groovy.apache.org by su...@apache.org on 2022/09/17 18:32:30 UTC

[groovy] branch master updated: GROOVY-10278: reuse `targetJavaVersion`

This is an automated email from the ASF dual-hosted git repository.

sunlan pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/groovy.git


The following commit(s) were added to refs/heads/master by this push:
     new 86352d052b GROOVY-10278: reuse `targetJavaVersion`
86352d052b is described below

commit 86352d052b63ca8efac4fec95a3fe26506f5e92a
Author: Daniel Sun <su...@apache.org>
AuthorDate: Sun Sep 18 02:31:52 2022 +0800

    GROOVY-10278: reuse `targetJavaVersion`
---
 gradle/idea.gradle | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/gradle/idea.gradle b/gradle/idea.gradle
index 1166e206e8..159e42e5bd 100644
--- a/gradle/idea.gradle
+++ b/gradle/idea.gradle
@@ -50,8 +50,8 @@ if (gradle.startParameter.taskNames.any { it =~ /(?i)idea/ }) {
 
                     // jdk, language level fix
                     def pRoot = node.component.find { it.'@name' == 'ProjectRootManager' }
-                    pRoot.'@languageLevel' = 'JDK_11'
-                    pRoot.'@project-jdk-name' = '11'
+                    pRoot.'@languageLevel' = 'JDK_' + sharedConfiguration.targetJavaVersion.get()
+                    pRoot.'@project-jdk-name' = sharedConfiguration.targetJavaVersion.get()
 
                     // Use git
                     def vcsConfig = node.component.find { it.'@name' == 'VcsDirectoryMappings' }