-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
79 lines (69 loc) · 1.93 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
group 'com.hania'
version '1.0-SNAPSHOT'
buildscript {
repositories {
jcenter()
}
dependencies {
classpath 'de.gliderpilot.gradle.jnlp:gradle-jnlp-plugin:+'
}
}
apply plugin: 'java'
apply plugin: 'groovy'
apply plugin: 'de.gliderpilot.jnlp'
sourceCompatibility = 1.8
repositories {
mavenCentral()
}
dependencies {
testCompile group: 'org.spockframework', name: 'spock-core', version: '1.1-groovy-2.4'
testCompile group: 'junit', name: 'junit', version: '4.12'
}
jnlp {
href 'launch.jnlp'
codebase 'http://localhost:8080/'
spec '1.0'
j2seParams = [version: '1.0+', 'max-heap-size': '256m']
signJarAddedManifestEntries = [
'Codebase': 'http://localhost:8080',
'Permissions': 'all-permissions',
'Application-Name': "${project.name}"
]
signJarRemovedManifestEntries = '(?:Trusted-Only|Trusted-Library|.*-Digest)'
useVersions = true
usePack200 = false
mainClassName = 'com.hania.Runner'
withXml {
information {
title project.name
vendor project.group ?: project.name
}
security {
'all-permissions'()
}
}
desc = {
'application-desc'('main-class': "${project.jnlp.mainClassName}") {
argument('-verbose')
}
}
signJarParams = [alias: 'calc', storepass: 'hania123']
}
task genkey {
doLast {
ant.genkey(alias: 'calc', storepass: 'hania123', dname: 'CN=hvvka, OU=Electronics Department, O=PWr, L=Breslau, ST=Dolny Slask, C=PL')
}
}
task createJar(type: Jar) {
manifest {
attributes 'Implementation-Title': rootProject.name,
'Implementation-Version': version,
'Main-Class': 'com.hania.Runner'
}
baseName = project.name
from { configurations.compile.collect { it.isDirectory() ? it : zipTree(it) } }
with jar
}
task wrapper(type: Wrapper) {
gradleVersion = '4.7'
}