-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
49 lines (43 loc) · 1.09 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
apply plugin: 'java'
apply plugin: 'eclipse'
version = '1.2.1'
sourceCompatibility = 1.8
targetCompatibility = 1.8
compileJava.options.encoding = 'UTF-8'
// Creates the jar with all dependencies included inside
task fatJar(type: Jar) {
manifest {
attributes 'Main-Class': 'net.darmo_creations.minesweeper.Minesweeper',
'Class-Path': '.'
}
// Packs all dependencies into the jar.
from {
configurations.compile.collect {
it.isDirectory() ? it : zipTree(it)
}
}
with jar
// end
}
// Creates the distributable jar
task createZip(type: Zip) {
from '/'
include 'LICENSE'
from 'build/libs/'
include 'Minesweeper-' + version + '.jar'
archiveName 'Minesweeper-' + version + '.zip'
destinationDir(file('/'))
}
// Where to find the project's dependencies
repositories {
jcenter()
}
// Dependencies for production and test code
dependencies {
// The production code uses the SLF4J logging API at compile time
compile 'org.slf4j:slf4j-api:1.7.21'
// GUI-Framework
compile files('libs/GUI-Framework-1.5.jar')
// JUnit
testCompile 'junit:junit:4.12'
}