Skip to content

Instantly share code, notes, and snippets.

@bloatfan
Last active August 1, 2017 07:42
Show Gist options
  • Save bloatfan/7932cab2d82da99e319bccb920cbeeab to your computer and use it in GitHub Desktop.
Save bloatfan/7932cab2d82da99e319bccb920cbeeab to your computer and use it in GitHub Desktop.
apply plugin: 'java'
apply plugin: 'application'
sourceCompatibility = 1.8
version = '1.0'
mainClassName='com.hello.Application'
jar {
manifest {
attributes 'Implementation-Title': 'Gradle Quickstart',
'Implementation-Version': version,
'Main-Class': 'com.hello.Application'
}
from {
configurations.compile.collect { it.isDirectory() ? it : zipTree(it) }
}
}
repositories {
mavenCentral()
}
dependencies {
compile 'org.springframework:spring-context:4.3.10.RELEASE'
runtime 'org.springframework:spring-context:4.3.10.RELEASE'
testCompile group: 'junit', name: 'junit', version: '4.+'
}
sourceSets {
main {
java {
srcDirs = ['src/main/java']
}
resources {
srcDirs = ['src/main/resources']
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment