Skip to content

Add Gradle buildscript dependency for LabKey plugins#1341

Merged
labkey-tchad merged 1 commit intodevelopfrom
fb_gradlePluginImport
Apr 16, 2026
Merged

Add Gradle buildscript dependency for LabKey plugins#1341
labkey-tchad merged 1 commit intodevelopfrom
fb_gradlePluginImport

Conversation

@labkey-tchad
Copy link
Copy Markdown
Member

Rationale

IntelliJ doesn't seem to recognize buildscript dependencies that come from settings.gradle. This causes class imports from our gradle plugin to show up as errors in the IDE.
With some experimentation, I discovered that adding the dependency to the root build.gradle makes IntelliJ recognize the imports throughout the project.
In addition to getting code assistance in our Gradle files, this will prevent IntelliJ's "Optimize Imports" from removing org.labkey.gradle.util.ExternalDependency from files that need it.

Before:
image

After:
image

Related Pull Requests

  • N/A

Changes

  • Add Gradle buildscript dependency for LabKey plugins

Allows IntelliJ to resolve related class imports
@labkey-tchad labkey-tchad self-assigned this Apr 16, 2026
Copy link
Copy Markdown
Contributor

@labkey-susanh labkey-susanh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great! I'm glad there's finally a solution for this very annoying behavior.

@labkey-tchad labkey-tchad merged commit 82c26b5 into develop Apr 16, 2026
9 checks passed
@labkey-tchad labkey-tchad deleted the fb_gradlePluginImport branch April 16, 2026 20:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants