forked from reposense/RepoSense
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
97 lines (79 loc) · 2.33 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
plugins {
id 'java'
id 'checkstyle'
id 'idea'
id 'application'
id 'com.github.johnrengelman.shadow' version '2.0.4'
id 'com.liferay.node' version '4.4.0'
}
mainClassName = 'reposense.RepoSense'
node.nodeVersion = '10.5.0'
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
repositories {
mavenCentral()
}
wrapper {
gradleVersion = '4.9'
}
checkstyle {
toolVersion = '8.1'
}
test {
testLogging {
events 'passed', 'skipped', 'failed'
showStandardStreams = true
}
}
sourceSets {
systemtest {
compileClasspath += main.output + test.output
runtimeClasspath += main.output + test.output
java.srcDir file('src/systemtest/java')
resources.srcDir file('src/systemtest/resources')
}
}
configurations {
systemtestImplementation.extendsFrom testImplementation
systemtestRuntime.extendsFrom testRuntime
}
dependencies {
implementation group: 'com.github.javaparser', name: 'javaparser-core', version: '3.0.1'
implementation group: 'com.google.code.gson' ,name: 'gson', version:'2.8.5'
implementation group: 'org.apache.ant', name: 'ant', version: '1.10.3'
implementation group: 'net.sourceforge.argparse4j', name: 'argparse4j', version: '0.8.1'
implementation group: 'net.freeutils', name: 'jlhttp', version: '2.4'
testImplementation group: 'junit', name: 'junit', version: '4.12'
}
shadowJar {
archiveName = 'RepoSense.jar'
destinationDir = file("${buildDir}/jar/")
}
task zipReport(dependsOn: 'npmRunSpuild', type: Zip) {
from 'frontend/build/'
baseName = 'templateZip'
destinationDir = file('src/main/resources')
}
tasks.shadowJar.dependsOn('zipReport');
tasks.run.dependsOn('zipReport');
task systemtest(dependsOn: 'zipReport', type: Test) {
testClassesDirs = sourceSets.systemtest.output.classesDirs
classpath = sourceSets.systemtest.runtimeClasspath
testLogging {
events 'passed', 'skipped', 'failed'
showStandardStreams = true
}
}
idea {
module {
sourceSets.systemtest.allSource.srcDirs.each { srcDir -> module.testSourceDirs += srcDir }
}
}
run {
//the second arguments indicates the default value associated with the property.
args System.getProperty('args', '').split()
}
tasks.withType(Copy) {
includeEmptyDirs = true
}
defaultTasks 'clean', 'build', 'systemtest'