From dda66db3654576d290783997bebadee05ebfe5f3 Mon Sep 17 00:00:00 2001 From: Joel Klinghed Date: Tue, 10 Jan 2017 09:27:10 +0100 Subject: All the rest --- src/main/groovy/FlycheckAndroidJavaTask.groovy | 30 ++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) create mode 100644 src/main/groovy/FlycheckAndroidJavaTask.groovy (limited to 'src/main/groovy/FlycheckAndroidJavaTask.groovy') diff --git a/src/main/groovy/FlycheckAndroidJavaTask.groovy b/src/main/groovy/FlycheckAndroidJavaTask.groovy new file mode 100644 index 0000000..28ca6bb --- /dev/null +++ b/src/main/groovy/FlycheckAndroidJavaTask.groovy @@ -0,0 +1,30 @@ +package org.thejk + +import org.gradle.api.DefaultTask +import org.gradle.api.tasks.TaskAction +import org.gradle.api.tasks.compile.JavaCompile + +class FlycheckAndroidJavaTask extends DefaultTask { + FlycheckAndroidJavaTask() { + def generate = project.tasks.findByName('generateDebugSources') + if (generate) { + dependsOn generate + } + } + + @TaskAction + def action() { + def compile = project.tasks.findByName('compileDebugJavaWithJavac') + if (compile instanceof JavaCompile) { + println '***' + println 'args=' + compile.options.compilerArgs + println 'encoding=' + compile.options.encoding + println 'bootcp=' + compile.options.bootClasspath + println 'cp=' + compile.classpath.asPath + println 'source=' + compile.sourceCompatibility + println 'target=' + compile.targetCompatibility + println 'files=' + compile.inputs.files.asPath + println 'output=' + compile.destinationDir + } + } +} -- cgit v1.2.3-70-g09d2