Skip to content

Instantly share code, notes, and snippets.

@xconnecting
Created October 26, 2012 06:10
Show Gist options
  • Star 3 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save xconnecting/3957190 to your computer and use it in GitHub Desktop.
Save xconnecting/3957190 to your computer and use it in GitHub Desktop.
Use custom Ant task from Gradle
apply plugin: 'java'
apply plugin: 'eclipse'
apply plugin: 'maven'
configurations { taskdef }
repositories { mavenCentral() }
dependencies { taskdef 'java2html:j2h:1.3.1' }
task java2html << {
def basedir = '.'
ant.taskdef(name:'java2html'
,classpath:configurations.taskdef.asPath
, classname:"com.java2html.Java2HTMLTask"
)
ant.java2html{
fileset(dir: 'src/main/java'){
include (name: '*.java')
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment