-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
86 lines (70 loc) · 2.05 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
plugins {
id 'java'
id 'eclipse'
id 'distribution'
}
group = 'com.newrelic.labs'
version = '1.1'
repositories {
mavenCentral()
maven {
url "http://maven.icm.edu.pl/artifactory/repo/"
}
flatDir {
dirs 'lib'
}
}
configurations {
provided
compile.extendsFrom provided
}
distributions {
main {
baseName = 'softwareag-ums'
contents {
from {
'build/archive'
}
}
}
}
dependencies {
// This dependency is used by the application.
implementation 'com.google.guava:guava:28.0-jre'
compile group: 'com.fasterxml.jackson.core', name: 'jackson-databind', version: '2.6.7.1'
// https://mvnrepository.com/artifact/com.softwareag/tibjms
//did not work
//compile group: 'com.softwareag', name: 'tibjms', version: '4.4.3'
// https://mvnrepository.com/artifact/javax.jms/javax.jms-api
compile group: 'javax.jms', name: 'javax.jms-api', version: '2.0.1'
// https://mvnrepository.com/artifact/com.googlecode.json-simple/json-simple
compile group: 'com.googlecode.json-simple', name: 'json-simple', version: '1.1.1'
compile group: 'com.beust', name: 'jcommander', version: '1.72'
provided fileTree(dir: 'lib', includes: ['*.jar'])
// Use JUnit test framework
testImplementation 'junit:junit:4.12'
}
task copyNRIFiles(dependsOn: 'allInOneJar', type: Copy) {
from 'config'
from('build/distributions') {
include '*.jar'
}
from 'scripts'
into 'build/archive'
}
task allInOneJar(type: Jar) {
manifest {
attributes 'Implementation-Title': project.group + '.' + project.name,
'Implementation-Vendor-Id': 'New Relic Labs',
'Implementation-Version': version,
"Main-Class": "com.newrelic.nri.softwareag.ums.Main"
}
archiveName 'softwareag-ums.jar'
destinationDir = file("$distsDir")
from { configurations.compile.collect { it.isDirectory() ? it : zipTree(it) } }
with jar
}
jar.enabled=false
assemble.dependsOn "allInOneJar"
distTar.dependsOn "copyNRIFiles"
distZip.dependsOn "copyNRIFiles"