Search code examples
grailsmavenintellij-ideajavadoc

Manage source and javadoc for Grails automatic dependencies in IntelliJ IDEA?


How do I attach source and javadoc to libraries in IntelliJ IDEA that are linked automatically by Grails dependency resolution and are not explicitly listed in the IDEA project settings?

For example in BuildConfig.groovy:

grails.project.dependency.resolution = {
    repositories {
        mavenRepo "http://oss.sonatype.org/content/repositories/releases/"
    }
    dependencies {
        runtime 'org.elasticsearch:elasticsearch:0.17.7'
    }
}

Is there a method to have IDEA automatically pick up the source and javadoc from the Maven repository?


Solution

  • IDEA attached the source automatically to the project plugin module. The JavaDoc can be manually attached to the plugin module in the project structure interface at:

    File -> Project Structure -> Project Settings -> Modules -> project name-grailsPlugins -> Paths -> JavaDoc

    IDEA project structure