I’m still somewhat new to Gradle. I’m in a process to check if I can upgrade an old ant script to gradle. This build creates a JavaFX jar (i.e. the ant task fx:jar, not the normal jar), merges and obfuscate some of our internal libs to the main jar and then builds installers for all platforms (the last step is done in separate build script because it must be run on each target hardware because of javafx). Anyway the idea is to do the compile/test/obfuscate in one part/only once and do the packaging in paraller (since it must anyway be done on each target platform).
I would like to do the same in gradle. Has anyone experience with this?
The only gradle+javafx related “thing” seems to be https://bitbucket.org/shemnon/javafx-gradle/ and that has not been updated since 2014-10-30. Also that does not seems to give as much configuration as the ant tasks do, e.g. I need a custom .iss file override. Is the only option to try to use the ant tasks from gradle? (I have tested the javapackager command line utility a bit, but the ant task seems better).
Also for proguard, it seems all the examples I have found use local paths for injars. If one of the injars comes from internal repo, I guess the only way is to download it first to some folder under build or try to search the gradle cache? Just if there is a more “gradle way” to do it, it would be nice to know. Ultimately, the best would be if I could just create an “obfuscate” configuration scope and those would be automatically merged (also essentially removing the merged dependencies), this is something I know is doable in ant+ivy (since I have done it, but it was somewhat ugly implementation). Then I could maybe use a separate module which would use that as a “library”/dependency and create a thin JavaFX wrapper jar to launch it.
I also created a stackoverflow question a while ago (which is mostly similar, it is for a different project; has multiple modules) http://stackoverflow.com/questions/31810500/gradle-project-with-multiple-modules-and-proguard