forked from NCIP/catissue-dynamic-extensions
-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathbuild.gradle
115 lines (91 loc) · 3.54 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
import org.apache.tools.ant.filters.ReplaceTokens
import org.apache.tools.ant.taskdefs.condition.Os
import static groovy.io.FileType.FILES
apply plugin: 'java'
apply plugin: 'eclipse'
apply plugin: 'idea'
def getTodayDate() {
def today = new Date()
return String.valueOf(today.getTime())
}
def getCommitRevision() {
def revCmd = "git rev-parse --short HEAD"
def revision = revCmd.execute()
return revision.text.trim()
}
def getBranch() {
def branchCmd = "git symbolic-ref -q --short HEAD";
def branch = branchCmd.execute().text.trim();
if (branch.length() == 0) {
branchCmd = "git describe --tags --exact-match";
branch = branchCmd.execute().text.trim();
}
return branch;
}
jar {
baseName = 'os-dynamic-forms'
version = getBranch()
manifest {
attributes("os-library-name": "dynamic-forms")
attributes("built-on": getTodayDate())
attributes("commit": getCommitRevision())
attributes("version": getBranch())
}
}
sourceCompatibility = 1.8
targetCompatibility = 1.8
repositories {
mavenCentral()
}
configurations {
ajc
aspects
aspectCompile
providedCompile
compile {
extendsFrom aspects
}
}
configurations.all {
transitive = false
}
sourceSets {
main.compileClasspath += configurations.providedCompile
test.compileClasspath += configurations.providedCompile
test.runtimeClasspath += configurations.providedCompile
}
idea {
module {
scopes.PROVIDED.plus += [configurations.providedCompile]
}
}
def springVersion = "4.3.30.RELEASE"
dependencies {
compile group: 'javax.servlet', name: 'javax.servlet-api', version: '4.0.1'
compile group: 'commons-beanutils', name: 'commons-beanutils', version:'1.9.4'
compile group: 'commons-collections', name: 'commons-collections', version:'3.2.1'
compile group: 'commons-logging', name: 'commons-logging', version:'1.2'
compile group: 'commons-io', name: 'commons-io', version:'2.4'
compile group: 'com.fasterxml', name: 'classmate', version: '1.4.0'
compile group: 'com.fasterxml.jackson.core', name: 'jackson-annotations', version:'2.12.4'
compile group: 'com.fasterxml.jackson.core', name: 'jackson-core', version:'2.12.4'
compile group: 'com.fasterxml.jackson.core', name: 'jackson-databind', version:'2.12.4'
compile group: 'com.google.code.gson', name: 'gson', version:'2.3.1'
compile group: 'com.thoughtworks.xstream', name: 'xstream', version:'1.4.17'
compile group: 'net.sf.opencsv', name: 'opencsv', version:'2.3'
compile group: 'net.sf.ehcache', name: 'ehcache', version:'1.2.3'
compile group: 'org.antlr', name: 'antlr4', version: '4.5.1'
compile group: 'org.apache.commons', name: 'commons-digester3', version:'3.2'
compile group: 'org.apache.commons', name: 'commons-lang3', version:'3.12.0'
compile group: 'org.apache.commons', name: 'commons-text', version:'1.9'
compile group: 'org.apache.logging.log4j', name: 'log4j-api', version: '2.16.0'
compile group: 'org.scijava', name: 'jep', version:'2.4.2'
compile group: 'org.liquibase', name: 'liquibase-core', version:'3.3.3'
compile group: 'org.springframework', name: 'spring-beans', version:springVersion
compile group: 'org.springframework', name: 'spring-core', version:springVersion
compile group: 'org.springframework', name: 'spring-jdbc', version:springVersion
compile group: 'org.springframework', name: 'spring-tx', version:springVersion
}
sourceSets.main.compileClasspath += configurations.providedCompile
sourceSets.test.compileClasspath += configurations.providedCompile
sourceSets.test.runtimeClasspath += configurations.providedCompile