-
Notifications
You must be signed in to change notification settings - Fork 44
/
Copy pathbuild.gradle
54 lines (45 loc) · 1.44 KB
/
build.gradle
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
buildscript {
repositories {
jcenter()
}
dependencies {
classpath 'io.ratpack:ratpack-gradle:1.0.0',
'com.github.jengelman.gradle.plugins:shadow:1.2.1'
}
}
if (!JavaVersion.current().java8Compatible) {
throw new IllegalStateException("Must be built with Java 8 or higher")
}
// The “ratpack” plugin applies the “application” plugin, making it easy to create a standalone application.
// See: http://gradle.org/docs/current/userguide/application_plugin.html
apply plugin: "io.ratpack.ratpack-java"
apply plugin: "com.github.johnrengelman.shadow"
repositories {
jcenter()
}
dependencies {
testCompile 'junit:junit:4.11'
// This is a Guice ratpack app
compile ratpack.dependency("guice")
runtime 'org.slf4j:slf4j-simple:1.7.10'
}
// The “ratpack” plugin is IDEA aware.
// It will create a run configuration in IDEA to launch your app in your IDE, with hot reloading.
apply plugin: "idea"
idea {
project {
//use JDK 1.8 in idea
jdkName "1.8"
languageLevel "1.8"
ipr {
withXml { provider ->
def node = provider.asNode()
//configure git support for the project in idea
node.component.find { it.'@name' == 'VcsDirectoryMappings' }?.mapping[0].'@vcs' = 'Git'
}
}
}
}
//some CI config
apply from: file("gradle/ci.gradle")
mainClassName = "ratpack.example.java.MyApp"