gwt-gradle-plugin icon indicating copy to clipboard operation
gwt-gradle-plugin copied to clipboard

Include additional Sources for recompile in gwtSuperDev Task

Open confile opened this issue 10 years ago • 2 comments

I have a second project which I included in my main project with:

dependencies {  
  compile(project(':core-project')) {
    transitive = false
  }
}

The core-project is a library project. When I run gradle gwtSuperDev and change files in my main project recompile takes place but not if I change files in my core-project.

How can I make that the core-project sources are also recompiled in SuperDevMode when they have changed?

confile avatar Feb 12 '15 02:02 confile

I think, the following should work:

dependencies {
    compile project(':core-project')
}

gwt {
    src += files(project(':core-project').sourceSets.main.allJava.srcDirs) + files(project(':core-project').sourceSets.main.output.resourcesDir)
}

steffenschaefer avatar Mar 03 '15 17:03 steffenschaefer

Thanks - that solution works for me, but it's a bit clunky. Not only do I have to list all of my dependencies twice, but I also have to list any transitive dependencies that my project wouldn't otherwise know about in order to see changes to them.

It would be great if the plugin could somehow automatically figure out all of the sources that might affect the current project.

ekuefler avatar Mar 13 '15 19:03 ekuefler