I\'m trying to compile our jsp files using jspc within gradle but am getting an exception.
Here is the pertinent gradle section
//tomcatHome is defin
Instead of using catalina-tasks.xml
from Tomcat's bin
directory you can use the Tomcat JAR file that includes the class org.apache.jasper.JspC
instead. If there are any libraries missing for your JSP compilation you can easily add them to the configuration jasper
.
configurations {
jasper
}
repositories {
mavenCentral()
}
dependencies {
jasper 'org.apache.tomcat:jasper:6.0.33',
'javax.servlet:jstl:1.1.2',
'taglibs:standard:1.1.2'
}
test.doLast {
ant.taskdef(classname: 'org.apache.jasper.JspC', name: 'jasper', classpath: configurations.jasper.asPath)
ant.jasper(validateXml: false, uriRoot: webAppDir, outputDir: "$buildDir/jspc")
}