-
Notifications
You must be signed in to change notification settings - Fork 111
/
build.gradle
108 lines (80 loc) · 2.62 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
plugins {
id 'application'
id 'com.github.johnrengelman.shadow' version '7.1.1'
// Used by release.gradle
id 'maven-publish'
id 'signing'
id 'io.codearte.nexus-staging' version '0.30.0'
}
apply plugin: 'application'
apply plugin: 'com.github.johnrengelman.shadow'
group 'nl.martijndwars'
version '5.1.2-SNAPSHOT'
repositories {
mavenLocal()
mavenCentral()
}
dependencies {
// For CLI
implementation group: 'com.beust', name: 'jcommander', version: '1.81'
// For making HTTP requests
implementation group: 'org.apache.httpcomponents', name: 'httpasyncclient', version: '4.1.5'
// For making async HTTP requests
implementation group: 'org.asynchttpclient', name: 'async-http-client', version: '2.12.3'
// For cryptographic operations
shadow group: 'org.bouncycastle', name: 'bcprov-jdk15on', version: '1.70'
// For creating and signing JWT
implementation group: 'org.bitbucket.b_c', name: 'jose4j', version: '0.7.9'
// For parsing JSON
testImplementation group: 'com.google.code.gson', name: 'gson', version: '2.8.9'
// For making HTTP requests
testImplementation group: 'org.apache.httpcomponents', name: 'fluent-hc', version: '4.5.13'
// For testing, obviously
testImplementation group: 'org.junit.jupiter', name: 'junit-jupiter-api', version: '5.8.1'
// For running JUnit tests
testRuntimeOnly group: 'org.junit.jupiter', name: 'junit-jupiter-engine', version: '5.8.1'
// For turning InputStream to String
testImplementation group: 'commons-io', name: 'commons-io', version: '2.11.0'
// For reading the demo vapid keypair from a pem file
testImplementation group: 'org.bouncycastle', name: 'bcpkix-jdk15on', version: '1.70'
// For verifying Base64Encoder results in unit tests
testImplementation group: 'com.google.guava', name: 'guava', version: '31.0.1-jre'
}
wrapper {
gradleVersion = '5.1'
}
compileJava {
sourceCompatibility = 1.8
targetCompatibility = 1.8
}
compileTestJava {
sourceCompatibility = 1.8
}
mainClassName = 'nl.martijndwars.webpush.cli.Cli'
run {
classpath configurations.shadow.files
}
test {
useJUnitPlatform()
testLogging {
events 'PASSED', 'FAILED', 'SKIPPED'
showStandardStreams true
exceptionFormat 'full'
}
exclude '**/SeleniumTests.class'
}
task javadocJar(type: Jar) {
classifier = 'javadoc'
from javadoc
}
task sourcesJar(type: Jar) {
classifier = 'sources'
from sourceSets.main.allSource
}
artifacts {
archives javadocJar
archives sourcesJar
}
if (hasProperty('release')) {
apply from: 'release.gradle'
}