-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
45 lines (37 loc) · 1.17 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
apply plugin: 'java'
apply plugin: 'eclipse'
dependencies {
compile files('./libs/gson-2.2.4.jar')
compile files('./libs/pircbot.jar')
}
defaultTasks 'compile' //Seperate by commas for more
task compile << {
print "Hello, world!"
}
task run(dependsOn: 'compile') << {
print "Hello, world!"
}
jar {
manifest {
attributes 'Class-Path': './libs/pircbot.jar, ./libs/gson-2.2.4.jar'
}
}
eclipse {
project {
name = 'Program-Scheduler'
buildCommand 'org.eclipse.jdt.core.javabuilder'
natures 'com.springsource.sts.gradle.core.nature', 'org.eclipse.jdt.groovy.core.groovyNature'
}
classpath {
file {
withXml {
def node = it.asNode()
node.appendNode('classpathentry', [kind: 'src', path: 'src/main/java']) //Add the source to the classpath
// Add the libraries to the classpath
node.appendNode('classpathentry', [kind: 'lib', path: 'libs/gson-2.2.4.jar'])
node.appendNode('classpathentry', [kind: 'lib', path: 'libs/pircbot.jar'])
node.appendNode('classpathentry', [kind: 'output', path: 'bin']) //Add the output path to the classpath
}
}
}
}