buildscript { repositories { jcenter() } } plugins { id 'java' id 'maven-publish' } //create a single Jar with all dependencies group = 'de.openea' version = '2.2.0' description = "EvA2" sourceCompatibility = 1.8 targetCompatibility = 1.8 task fatJar(type: Jar) { manifest { attributes 'Implementation-Title': 'Gradle Jar File Example', 'Implementation-Version': version, 'Main-Class': 'eva2.gui.Main' } baseName = project.name + '-all' from { configurations.compile.collect { it.isDirectory() ? it : zipTree(it) } } with jar } repositories { mavenCentral() } dependencies { compile group: 'javax.help', name: 'javahelp', version: '2.0.05' compile group: 'org.yaml', name: 'snakeyaml', version: '1.16' compile group: 'gov.nist.math', name: 'jama', version: '1.0.3' testCompile group: 'junit', name: 'junit', version: '4.12' testCompile group: 'org.mockito', name: 'mockito-core', version: '1.+' } modifyPom { project { name 'EvA2' description 'Gradle plugin that provides tasks for configuring and uploading artifacts to Sonatype Nexus.' url 'http://www.ra.cs.uni-tuebingen.de/software/eva2/' inceptionYear '2008' scm { url 'https://gitlab.cs.uni-tuebingen.de/eva2/eva2/' connection 'scm:https://gitlab.cs.uni-tuebingen.de/eva2/eva2/.git' developerConnection 'scm:https://gitlab.cs.uni-tuebingen.de/eva2/eva2/.git' } licenses { license { name 'GNU Lesser General Public License, Version 3.0' url 'http://www.gnu.org/licenses/lgpl-3.0.html' distribution 'repo' } } developers { developer { id 'halfdan' name 'Fabian Becker' email 'halfdan@xnorfz.de' } } } } extraArchive { sources = true tests = true javadoc = true }