grpc-java/examples/build.gradle

49 lines
1.3 KiB
Groovy

apply plugin: 'application'
apply plugin: 'protobuf'
description = "grpc Examples"
buildscript {
repositories {
mavenCentral()
}
dependencies {
classpath libraries.protobuf_plugin
}
}
dependencies {
compile project(':grpc-core'),
project(':grpc-netty'),
project(':grpc-okhttp'),
project(':grpc-stub'),
libraries.jsonp
}
protobufCodeGenPlugins = ["java_plugin:$javaPluginPath"]
generateProto.dependsOn ':grpc-compiler:java_pluginExecutable'
task routeGuideServer(type: JavaExec) {
main = "io.grpc.examples.routeguide.RouteGuideServer"
description = "Executes the route guide server."
classpath = sourceSets.main.runtimeClasspath
}
task routeGuideClient(type: JavaExec) {
main = "io.grpc.examples.routeguide.RouteGuideClient"
description = "Executes the route guide client."
classpath = sourceSets.main.runtimeClasspath
}
task helloWorldServer(type: JavaExec) {
main = "io.grpc.examples.helloworld.HelloWorldServer"
description = "Executes the hello world server."
classpath = sourceSets.main.runtimeClasspath
}
task helloWorldClient(type: JavaExec) {
main = "io.grpc.examples.helloworld.HelloWorldClient"
description = "Executes the hello world client."
classpath = sourceSets.main.runtimeClasspath
}