You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@grails.apache.org by jd...@apache.org on 2026/07/26 20:33:34 UTC
(grails-intellij-plugin) 14/35: Nest the compiler tier under libs and complete the group hierarchy
This is an automated email from the ASF dual-hosted git repository.
jdaugherty pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/grails-intellij-plugin.git
commit 369fa5731db2f148ac6d3168c1e1c34c86973521
Author: James Daugherty <jd...@jdresources.net>
AuthorDate: Sun Jul 26 11:29:14 2026 -0400
Nest the compiler tier under libs and complete the group hierarchy
Two corrections.
The compiler plugins move from a top-level compilerPlugins tier to a
subdirectory of the lib tier, so the source tiers mirror the packaged layout:
pluginModules/* are content modules and ship to lib/modules/, while everything
under libs/ -- compiler plugins included -- ships to lib/. The compiler
subdivision is a grouping within that tier, not a separate destination. The
convention plugin is renamed accordingly (build.compiler-plugin ->
build.lib-compiler) and the group becomes org.apache.grails.intellij.lib.compiler.
Two groups did not match the intended hierarchy:
plugin project org.apache.grails.intellij -> org.apache.grails.intellij.plugin
build-logic (unset) -> org.apache.grails.intellij.build
The full hierarchy is now:
org.apache.grails.intellij.build build-logic (Gradle DSL build code)
org.apache.grails.intellij.plugin the IntelliJ plugin
org.apache.grails.intellij.module the six content modules
org.apache.grails.intellij.lib gradle-tooling, grails-rt, testFramework
org.apache.grails.intellij.lib.compiler jps-plugin, grails-compiler-patch
Packaged jar names follow the same tiers, and the compileServer.plugin classpath
in plugin.xml is updated to match. Group is not part of any archive name, so the
distribution layout is unchanged by the group fixes -- verified.
Still outstanding, and deliberately last: the six content module NAMES are still
intellij.groovy.grails.*, because those are a three-way runtime contract with the
descriptor filenames and lib/modules/ jar names. They change in the dedicated
rename step, gated on runIde.
---
build-logic/build.gradle | 3 +++
...g.apache.grails.intellij.build.intellij-plugin.gradle | 2 +-
...org.apache.grails.intellij.build.lib-compiler.gradle} | 16 ++++++++++------
grails-compiler-patch/build.gradle | 2 +-
jps-plugin/build.gradle | 2 +-
resources/META-INF/plugin.xml | 2 +-
6 files changed, 17 insertions(+), 10 deletions(-)
diff --git a/build-logic/build.gradle b/build-logic/build.gradle
index 91b51c2..1668b53 100644
--- a/build-logic/build.gradle
+++ b/build-logic/build.gradle
@@ -21,6 +21,9 @@ plugins {
id 'groovy-gradle-plugin'
}
+// The Gradle DSL build code tier.
+group = 'org.apache.grails.intellij.build'
+
// Gradle plugins that the convention plugins apply. Declaring them here is what lets the
// convention plugins apply them WITHOUT a version, and it removes the previous fragility
// where 'org.jetbrains.intellij.platform.module' was applied version-free in every module
diff --git a/build-logic/src/main/groovy/org.apache.grails.intellij.build.intellij-plugin.gradle b/build-logic/src/main/groovy/org.apache.grails.intellij.build.intellij-plugin.gradle
index 247590c..86f6fe9 100644
--- a/build-logic/src/main/groovy/org.apache.grails.intellij.build.intellij-plugin.gradle
+++ b/build-logic/src/main/groovy/org.apache.grails.intellij.build.intellij-plugin.gradle
@@ -30,7 +30,7 @@ plugins {
id 'org.jetbrains.intellij.platform'
}
-group = 'org.apache.grails.intellij'
+group = 'org.apache.grails.intellij.plugin'
intellijPlatform {
// Pinned explicitly. This drives the distribution ZIP name, the plugin directory inside it,
diff --git a/build-logic/src/main/groovy/org.apache.grails.intellij.build.compiler-plugin.gradle b/build-logic/src/main/groovy/org.apache.grails.intellij.build.lib-compiler.gradle
similarity index 65%
rename from build-logic/src/main/groovy/org.apache.grails.intellij.build.compiler-plugin.gradle
rename to build-logic/src/main/groovy/org.apache.grails.intellij.build.lib-compiler.gradle
index 7f81405..03f8e29 100644
--- a/build-logic/src/main/groovy/org.apache.grails.intellij.build.compiler-plugin.gradle
+++ b/build-logic/src/main/groovy/org.apache.grails.intellij.build.lib-compiler.gradle
@@ -20,10 +20,14 @@
// A compiler plugin: code that runs inside the end user's JPS build process rather than in the
// IDE. These are the jars named by <compileServer.plugin classpath="..."/> in plugin.xml.
//
-// This is a distinct tier from lib/ on purpose. JPS resolves the classpath attribute by file
-// name and silently skips entries it cannot find, so these jar names are part of the plugin's
-// contract and must stay pinned and in sync with the descriptor -- unlike a plain library, whose
-// name nothing depends on. Keeping them in their own directory makes that obligation visible.
+// It lives under the lib tier (libs/compiler/*) rather than beside it, because the source tiers
+// mirror the packaged layout: pluginModules/* are content modules and ship to lib/modules/, while
+// everything in libs/ -- compiler plugins included -- ships to lib/. The compiler subdirectory is
+// a sub-grouping within that tier, not a separate destination.
+//
+// It is still called out separately because JPS resolves the classpath attribute by file name and
+// silently skips entries it cannot find, so these jar names are part of the plugin's contract and
+// must stay pinned and in sync with the descriptor. Nothing depends on a plain library's name.
plugins {
id 'org.apache.grails.intellij.build.intellij-platform'
@@ -32,12 +36,12 @@ plugins {
def shortName = projectDir.name
-group = 'org.apache.grails.intellij.compiler'
+group = 'org.apache.grails.intellij.lib.compiler'
base.archivesName = shortName
// Pinned, not derived. IPGP's default is "${rootProject.name}.${project.path with ':' -> '.'}",
// which tracks both the root project name and the project's depth in the tree; that is exactly
// how the descriptor's classpath attribute went stale before.
tasks.named('composedJar') { task ->
- task.archiveBaseName = "org.apache.grails.intellij.compiler.$shortName"
+ task.archiveBaseName = "org.apache.grails.intellij.lib.compiler.$shortName"
}
diff --git a/grails-compiler-patch/build.gradle b/grails-compiler-patch/build.gradle
index dad67cd..6bf6df5 100644
--- a/grails-compiler-patch/build.gradle
+++ b/grails-compiler-patch/build.gradle
@@ -14,7 +14,7 @@
* limitations under the License.
*/
plugins {
- id 'org.apache.grails.intellij.build.compiler-plugin'
+ id 'org.apache.grails.intellij.build.lib-compiler'
id 'org.apache.grails.intellij.build.java-legacy'
id 'org.apache.grails.intellij.build.legacy-layout'
}
diff --git a/jps-plugin/build.gradle b/jps-plugin/build.gradle
index 261d571..061ecac 100644
--- a/jps-plugin/build.gradle
+++ b/jps-plugin/build.gradle
@@ -14,7 +14,7 @@
* limitations under the License.
*/
plugins {
- id 'org.apache.grails.intellij.build.compiler-plugin'
+ id 'org.apache.grails.intellij.build.lib-compiler'
id 'org.apache.grails.intellij.build.java-legacy'
id 'org.apache.grails.intellij.build.legacy-layout'
}
diff --git a/resources/META-INF/plugin.xml b/resources/META-INF/plugin.xml
index ca6f492..7536939 100644
--- a/resources/META-INF/plugin.xml
+++ b/resources/META-INF/plugin.xml
@@ -323,7 +323,7 @@
builders with nothing more than a line in idea.log. These names are pinned by the
org.apache.grails.intellij.build.intellij-lib convention plugin rather than derived from
rootProject.name, which is what let this attribute go stale previously. -->
- <compileServer.plugin classpath="org.apache.grails.intellij.compiler.jps-plugin.jar;org.apache.grails.intellij.compiler.grails-compiler-patch.jar"/>
+ <compileServer.plugin classpath="org.apache.grails.intellij.lib.compiler.jps-plugin.jar;org.apache.grails.intellij.lib.compiler.grails-compiler-patch.jar"/>
<multiHostInjector implementation="org.jetbrains.plugins.grails.lang.gsp.GspCssInjector"/>
<multiHostInjector implementation="org.jetbrains.plugins.grails.references.constraints.GormRegexInjector"/>