apply plugin: 'war' configurations { webstart } dependencies { compile jnlpServlet, commonsLang, project(':encoding:server') providedCompile jeeApi webstart project(':bootstrap:client'), project(':encoding:client') } signedJarDir = 'build/libs/signed' task sign { description = 'Signs the client JARs which are to be distributed via WebStart.' inputs.files configurations.webstart outputs.files signedJarDir } << { file(signedJarDir).mkdirs() configurations.webstart.each { ant.signjar(alias: 'newops', storepass: 'newops', keystore: '.keystore', jar: it, destDir: signedJarDir) } } war { baseName = 'connect' from( signedJarDir ) { into 'webstart/lib' } clientJars = configurations.webstart.collect({ if(it.name == 'win32com-1.0.jar') { '\r\n' + '' } else { '' } }).join('\r\n') eachFile{ if(it.name == 'launch.jnlp') it.expand(version: version, island: 'Connect', dependencies: clientJars) else if(it.name == 'context.xml') it.expand(path: '/connect') } dependsOn configurations.webstart dependsOn sign }