gradle-gaelyk-plugin
gradle-gaelyk-plugin copied to clipboard
Allow to set groovyc target version
Currently I can not set target or source attribute on ant.groovyc task - gaelykPrecompileGroovlet, gaelykPrecompileTemplate.
And when I run gaeRun task with --debug switch I see "Annotations are not supported in the current runtime. Please make sure you are running on a JVM >= 1.5" on command output.
It is just in case "-Dgroovy.target.bytecode=1.6" switch is used. I used that switch because I am looking for fixing of following bug: Application with groovy sources placed in src/main/groovy works correctly. When I place same groovy sources to src/main/webapp/WEB-INF/groovy I got: "The class XYZ refers to the class XYZ and uses 1 parameters, but the referred class takes no parameters". And mentioned switch "groovy.target.bytecode" I used to set target jdk version of "hot-deploy"/rad Groovy Script recompiller.
I think the problem could be renamed to Groovy precompilation task do use the Gradle target and source Java versions because I suppose that's the real problem
@bmuschko could you have look on this issue? it's probably causing some nasty bugs w/ 1.7
We should probably automatically reuse the values of the properties sourceCompatibility
in the template project. I'd assume that you use 1.6 in this case right?
yeah, would be nice, sourceCompatibility
and targetCompatilibility
will be taken from JavaPlugin
but I'm not sure, how to do it.
OK, sounds good. I will put in a fix tonight.
great, thx!