-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathbuild.gradle
108 lines (92 loc) · 2.41 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 "java-library"
id "maven-publish"
id "eclipse"
id "com.google.protobuf" version "0.8.8"
}
group = "io.liftbridge"
version = "0.1.0-alpha0"
java {
sourceCompatibility = JavaVersion.VERSION_1_8
targetCompatibility = JavaVersion.VERSION_1_8
}
sourceSets {
main {
java {
srcDir "src/main/java"
srcDir "build/generated/source/proto/main/java"
srcDir "build/generated/source/proto/main/grpc"
}
}
}
publishing {
publications {
maven(MavenPublication) {
from components.java
pom {
scm {
connection = "scm:git:https://github.com/caioaao/java-liftbridge.git"
developerConnection = "scm:git:git@github.com:caioaao/java-liftbridge.git"
url = "https://github.com/caioaao/java-liftbridge"
}
licenses {
license {
name = "Apache 2.0"
url = "https://opensource.org/licenses/Apache-2.0"
}
}
}
}
}
repositories {
maven {
name = "myRepo"
url = "file://${buildDir}/repo"
}
}
}
repositories {
mavenCentral()
}
dependencies {
api "io.grpc:grpc-api:1.26.0"
implementation "io.grpc:grpc-stub:1.26.0"
implementation "io.grpc:grpc-protobuf:1.26.0"
implementation "com.google.protobuf:protobuf-java:3.11.0"
testImplementation "junit:junit:4.12"
testImplementation "io.grpc:grpc-netty:1.26.0"
testImplementation "org.apache.commons:commons-lang3:3.9"
testImplementation "org.awaitility:awaitility:4.0.1"
testImplementation "org.mockito:mockito-core:2.+"
protobuf files("liftbridge-api/")
}
jar {
manifest {
attributes("Implementation-Title": project.name,
"Implementation-Version": project.version)
}
}
test {
testLogging {
showStandardStreams = true
events "passed", "skipped", "failed"
}
}
tasks.withType(JavaCompile) {
options.compilerArgs << "-Xlint:unchecked" << "-Werror"
}
protobuf {
protoc {
artifact = "com.google.protobuf:protoc:3.7.0"
}
plugins {
grpc {
artifact = "io.grpc:protoc-gen-grpc-java:1.19.0"
}
}
generateProtoTasks {
all()*.plugins {
grpc {}
}
}
}