forked from MontiSecArc/intellij_msa_language_plugin
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
127 lines (106 loc) · 3.01 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
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
buildscript {
repositories {
jcenter()
mavenCentral()
maven { url 'https://dl.bintray.com/kotlin/kotlin-eap' }
maven {
url "https://oss.sonatype.org/content/repositories/snapshots/"
}
maven {
url 'http://dl.bintray.com/jetbrains/intellij-plugin-service'
}
}
dependencies {
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlinVersion"
classpath "org.jetbrains.intellij.plugins:gradle-intellij-plugin:0.2.0-SNAPSHOT"
}
}
apply plugin: "org.jetbrains.intellij"
group 'de.monticore.lang.montisecarc'
intellij {
pluginName name
version ideaVersion
downloadSources Boolean.valueOf(downloadIdeaSources)
updateSinceUntilBuild = false
instrumentCode = false
plugins = ['com.neueda4j.intellij.plugin.cypher:2.4.1', project(':GraphDatabase')]
}
apply plugin: 'java'
apply plugin: 'kotlin'
apply plugin: 'idea'
apply plugin: 'jacoco'
sourceCompatibility = javaVersion
targetCompatibility = javaVersion
tasks.withType(JavaCompile) { options.encoding = 'UTF-8' }
sourceSets {
main {
java.srcDirs "gen", "src/java"
kotlin.srcDirs "src/kotlin"
resources.srcDir "resources"
}
test {
kotlin.srcDirs "tests"
resources.srcDirs "testData"
}
}
test {
testLogging {
events 'skipped', 'failed'
exceptionFormat = 'full'
}
beforeSuite { suite ->
if (suite.className != null) {
println()
println(suite.className)
}
}
afterTest { desc, result ->
def c = '.'
if (result.resultType == TestResult.ResultType.FAILURE) {
c = 'X'
} else if (result.resultType == TestResult.ResultType.SKIPPED) {
c = 'S'
}
print(c)
System.out.flush()
}
afterSuite { println() }
}
repositories {
mavenCentral()
jcenter()
}
project.afterEvaluate {
def prepareSandboxTask = project.tasks.findByName("prepareSandbox")
prepareSandboxTask.doLast {
def libFiles = new File("$prepareSandboxTask.destinationDir/${project.name}/lib/")
libFiles.listFiles().each {
if(it.name.contains("kotlin")) {
delete(it)
}
}
}
}
dependencies {
compile group: 'com.beust', name:'klaxon', version:'0.27'
compile 'com.github.kittinunf.fuel:fuel:1.5.0' //for JVM
compile "org.jetbrains.kotlin:kotlin-stdlib:$kotlinVersion"
compile group: 'org.freemarker', name: 'freemarker', version: '2.3.25-incubating'
compile 'com.github.ben-manes.caffeine:caffeine:2.4.0'
}
jacocoTestReport {
reports {
xml.enabled true
html.enabled false
}
afterEvaluate {
classDirectories = files(classDirectories.files.collect {
fileTree(dir: it,
exclude: ['gen/**',
'graphdatabase/**',
'grammars/**'])
})
}
}
check.dependsOn jacocoTestReport
version = "$version"