-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.gradle
66 lines (55 loc) · 1.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
buildscript {
repositories {
mavenCentral()
}
dependencies {
classpath 'org.jetbrains.kotlin:kotlin-gradle-plugin:2.0.20'
}
}
subprojects {
apply plugin: 'java'
apply plugin: 'org.jetbrains.kotlin.jvm'
repositories {
//mavenLocal()
//maven { url = 'https://s01.oss.sonatype.org/content/repositories/snapshots/' }
mavenCentral()
}
dependencies {
// Infinitic
String version = '0.16.4'
implementation 'io.infinitic:infinitic-worker:' + version
implementation 'ch.qos.logback:logback-classic:1.4.5'
if (name == "common") {
implementation 'io.infinitic:infinitic-client:' + version
} else if (name == "contracts") {
// nothing
}
else {
implementation project(':common')
implementation project(':contracts')
}
}
if (name != "contracts" && name != "common") {
tasks.register('run-java', JavaExec) {
group = "worker"
mainClass = 'com.acme.common.Worker'
classpath = sourceSets.main.runtimeClasspath
args 'java/worker'
}
tasks.register('run-kotlin', JavaExec) {
group = "worker"
mainClass = 'com.acme.common.Worker'
classpath = sourceSets.main.runtimeClasspath
args 'kotlin/worker'
}
}
// Apply a specific Java toolchain to ease working on different environments.
java {
toolchain {
languageVersion = JavaLanguageVersion.of(17)
}
}
kotlin {
jvmToolchain(17)
}
}