forked from temporalio/samples-java
-
Notifications
You must be signed in to change notification settings - Fork 0
/
build.gradle
82 lines (70 loc) · 2.58 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
// Run 'gradle checkUpdates' to find out which dependencies have newer versions
plugins {
id 'net.minecrell.licenser' version '0.4.1'
id 'com.github.sherter.google-java-format' version '0.9'
id "net.ltgt.errorprone" version "1.3.0"
id 'name.remal.check-updates' version '1.1.0'
}
apply plugin: 'java'
apply plugin: 'com.github.sherter.google-java-format'
googleJavaFormat {
toolVersion '1.7'
}
java {
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
}
repositories {
maven {
url "https://plugins.gradle.org/m2/"
}
maven {
url "https://oss.sonatype.org/content/repositories/snapshots/"
}
mavenCentral()
}
dependencies {
implementation group: 'io.temporal', name: 'temporal-sdk', version: '1.0.1'
implementation group: 'commons-configuration', name: 'commons-configuration', version: '1.10'
implementation group: 'ch.qos.logback', name: 'logback-classic', version: '1.2.3'
testImplementation group: 'junit', name: 'junit', version: '4.13.1'
testImplementation group: 'org.mockito', name: 'mockito-all', version: '1.10.19'
testImplementation group: 'org.powermock', name: 'powermock-api-mockito', version: '1.7.4'
errorproneJavac("com.google.errorprone:javac:9+181-r4173-1")
errorprone("com.google.errorprone:error_prone_core:2.4.0")
}
compileJava {
dependsOn 'googleJavaFormat'
}
task execute(type: JavaExec) {
main = findProperty("mainClass") ?: ""
classpath = sourceSets.main.runtimeClasspath
}
license {
header rootProject.file('license-header.txt')
}
// Executes most of the hello workflows as a sanity check
task runHello {
doLast {
// Cron and Periodic are not in the list as they take long time to stop
["io.temporal.samples.hello.HelloActivity",
"io.temporal.samples.hello.HelloActivityRetry",
"io.temporal.samples.hello.HelloAsync",
"io.temporal.samples.hello.HelloAsyncActivityCompletion",
"io.temporal.samples.hello.HelloAsyncLambda",
"io.temporal.samples.hello.HelloChild",
"io.temporal.samples.hello.HelloException",
"io.temporal.samples.hello.HelloPolymorphicActivity",
"io.temporal.samples.hello.HelloQuery",
"io.temporal.samples.hello.HelloSaga",
"io.temporal.samples.hello.HelloSearchAttributes",
"io.temporal.samples.hello.HelloSignal"
].each { mainClass ->
println mainClass
javaexec {
classpath = sourceSets.main.runtimeClasspath
main = mainClass
}
}
}
}