File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -17,7 +17,7 @@ buildscript {
1717 classpath(Classpath .firebase_perf)
1818 classpath(Classpath .secrets_gradle_plugin)
1919 classpath(Classpath .kotlin_serialization_plugin)
20- classpath(" com.google.protobuf:protobuf-gradle-plugin:0.8.14 " )
20+ classpath(Classpath .protobuf_plugin )
2121 }
2222}
2323
Original file line number Diff line number Diff line change @@ -70,6 +70,7 @@ object Versions {
7070 const val markwon = " 4.6.2"
7171 const val timber = " 5.0.1"
7272 const val voyager = " 1.0.0"
73+ const val protobuf_plugin = " 0.8.14"
7374}
7475
7576object Classpath {
@@ -79,6 +80,7 @@ object Classpath {
7980 const val kotlin_gradle_plugin = " org.jetbrains.kotlin:kotlin-gradle-plugin:${Versions .kotlin} "
8081 const val kotlin_serialization_plugin = " org.jetbrains.kotlin:kotlin-serialization:${Versions .kotlin} "
8182 const val google_services = " com.google.gms:google-services:${Versions .google_services} "
83+ const val protobuf_plugin = " com.google.protobuf:protobuf-gradle-plugin:${Versions .protobuf_plugin} "
8284
8385 const val crashlytics_gradle = " com.google.firebase:firebase-crashlytics-gradle:${Versions .crashlytics_gradle} "
8486 const val bugsnag = " com.bugsnag:bugsnag-android-gradle-plugin:8.+"
Original file line number Diff line number Diff line change @@ -28,9 +28,9 @@ dependencies {
2828
2929}
3030
31- def generatedSrcRoot = file(" ${ layout.buildDirectory } /generated/source/proto/main/java" )
32- def generatedSrcRoot2 = file(" ${ layout.buildDirectory } /generated/source/proto/main/grpc" )
33- def generatedSrcRoot3 = file(" ${ layout.buildDirectory } /generated/source/proto/main/grpcKt" )
31+ def generatedSrcRoot = file(" ${ buildDir } /generated/source/proto/main/java" )
32+ def generatedSrcRoot2 = file(" ${ buildDir } /generated/source/proto/main/grpc" )
33+ def generatedSrcRoot3 = file(" ${ buildDir } /generated/source/proto/main/grpcKt" )
3434sourceSets. main {
3535 proto {
3636 srcDir " ${ rootDir} /model/proto"
@@ -41,7 +41,7 @@ sourceSets.main {
4141}
4242
4343compileJava {
44- options. generatedSourceOutputDirectory . set( generatedSrcRoot)
44+ options. annotationProcessorGeneratedSourcesDirectory generatedSrcRoot
4545}
4646
4747protobuf {
8787 exclude " **/*agora*/**"
8888}
8989
90- tasks . register( ' sourcesJar' , Jar ) {
90+ task sourcesJar ( type : Jar ) {
9191 from sourceSets. main. allSource
9292 archiveClassifier = ' sources'
9393 from generatedSrcRoot, generatedSrcRoot2, generatedSrcRoot3
You can’t perform that action at this time.
0 commit comments