Intellij can't resolve dependencies in Gradle with not default buildFile

Answered

build.gradle use loop to create tasks:

versions.each { shortVer, cfg ->
task "build_${shortVer}"(type: GradleBuild) {
tasks = ["buildPluginWithBunch", "test"]
buildFile = 'build_plugin.gradle'
startParameter.setProjectProperties(cfg)
}
}

 

0
4 comments

How do you declare the dependencies? Can you provide a sample project?

The build file must be added as gradle build file in project for the IDE to import its configuration including dependencies.

0

Here is the project I want to import: https://github.com/EmmyLua/IntelliJ-EmmyLua

`build.gradle` has added as gradle project, but I can't find any action to add the `build_plugin.gradle` as gradle project

0

Thank you for details. Created the https://youtrack.jetbrains.com/issue/IDEA-239634 Please follow it for updates.

0

Thank you for the help!

0

Please sign in to leave a comment.