-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Change implementation to
protobuf-javalite
- Loading branch information
Showing
29 changed files
with
349 additions
and
251 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
38 changes: 38 additions & 0 deletions
38
buildSrc/src/main/kotlin/co/raccoons/local/gradle/java/DependencyConfiguration.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
/* | ||
* Copyright 2023, Raccoons. Developing simple way to change. | ||
* | ||
* @license MIT | ||
*/ | ||
|
||
package co.raccoons.local.gradle.java | ||
|
||
import org.gradle.api.Plugin | ||
import org.gradle.api.Project | ||
|
||
/** | ||
* The scopes of the dependencies. | ||
*/ | ||
internal class DependencyConfiguration : Plugin<Project> { | ||
|
||
private val dependencyScopes = mutableMapOf<String, MutableList<String>>() | ||
|
||
/** @inheritDoc */ | ||
override fun apply(project: Project) { | ||
for ((configurationScope, dependencies) in dependencyScopes) { | ||
for (dependency in dependencies) { | ||
project.dependencies.add(configurationScope, dependency) | ||
} | ||
} | ||
} | ||
|
||
/** Adds dependency to the corresponding configuration scope. */ | ||
fun add(dependency: Dependency): DependencyConfiguration { | ||
this.dependencyScopes | ||
.getOrPut(dependency.configurationName()) { | ||
mutableListOf() | ||
} | ||
.add(dependency.dependencyNotation().toString()) | ||
|
||
return this | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
31 changes: 0 additions & 31 deletions
31
buildSrc/src/main/kotlin/co/raccoons/local/gradle/java/DependencyScope.kt
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.