Skip to content

Commit

Permalink
Convert datastore-proto to declarative syntax
Browse files Browse the repository at this point in the history
  • Loading branch information
tresat committed May 29, 2024
1 parent 62b3e97 commit 81a0e19
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 56 deletions.
8 changes: 8 additions & 0 deletions core/datastore-proto/build.gradle.dcl
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
androidLibrary {
namespace = "com.google.samples.apps.nowinandroid.core.datastore.proto"

// Setup protobuf configuration, generating lite Java and Kotlin classes
protobuf {
option = "lite" // TODO: This is modeled in a very limited manner for now
}
}
55 changes: 0 additions & 55 deletions core/datastore-proto/build.gradle.kts

This file was deleted.

2 changes: 1 addition & 1 deletion gradle/libs.versions.toml
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@ kotlin-jvm = { id = "org.jetbrains.kotlin.jvm" }
kotlin-serialization = { id = "org.jetbrains.kotlin.plugin.serialization" }
ksp = { id = "com.google.devtools.ksp" }
module-graph = { id = "com.jraska.module.graph.assertion", version.ref = "moduleGraph" }
protobuf = { id = "com.google.protobuf", version.ref = "protobufPlugin" }
protobuf = { id = "com.google.protobuf" }
roborazzi = { id = "io.github.takahirom.roborazzi", version.ref = "roborazzi" }
room = { id = "androidx.room" }
secrets = { id = "com.google.android.libraries.mapsplatform.secrets-gradle-plugin", version.ref = "secrets" }
Expand Down
9 changes: 9 additions & 0 deletions settings.gradle.dcl
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,15 @@ conventions {
schemaDirectory = "schemas"
}

protobuf {
version = "3.25.2"
generatedRootDir = "generated/source/proto"

dependencies {
protoc("com.google.protobuf:protoc:3.25.2") // TODO: How to use to the same version here without
}
}

testing {
jacoco {
version = "0.8.7"
Expand Down

0 comments on commit 81a0e19

Please sign in to comment.