Skip to content

Commit 11587b3

Browse files
committed
Remove usage of deprecated GUtil
1 parent 5d6103b commit 11587b3

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

src/main/groovy/com/google/protobuf/gradle/Utils.groovy

+3-4
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,6 @@ import org.gradle.api.Project
3535
import org.gradle.api.tasks.SourceSet
3636
import org.gradle.plugins.ide.idea.GenerateIdeaModule
3737
import org.gradle.plugins.ide.idea.model.IdeaModel
38-
import org.gradle.util.GUtil
3938

4039
/**
4140
* Utility classes.
@@ -48,7 +47,7 @@ class Utils {
4847
static String getConfigName(String sourceSetName, String type) {
4948
// same as DefaultSourceSet.configurationNameOf
5049
String baseName = sourceSetName == SourceSet.MAIN_SOURCE_SET_NAME ?
51-
'' : GUtil.toCamelCase(sourceSetName)
50+
'' : sourceSetName.capitalize()
5251
return StringUtils.uncapitalize(baseName + StringUtils.capitalize(type))
5352
}
5453

@@ -58,7 +57,7 @@ class Utils {
5857
*/
5958
static String getSourceSetSubstringForTaskNames(String sourceSetName) {
6059
return sourceSetName == SourceSet.MAIN_SOURCE_SET_NAME ?
61-
'' : GUtil.toCamelCase(sourceSetName)
60+
'' : sourceSetName.capitalize()
6261
}
6362

6463
private static final String ANDROID_BASE_PLUGIN_ID = "com.android.base"
@@ -92,7 +91,7 @@ class Utils {
9291
// Fortunately, the naming scheme is well defined:
9392
// https://kotlinlang.org/docs/reference/using-gradle.html#compiler-options
9493
Preconditions.checkState(isAndroidProject(project))
95-
return "compile" + GUtil.toCamelCase(variantName) + "Kotlin"
94+
return "compile" + variantName.capitalize() + "Kotlin"
9695
}
9796

9897
/**

0 commit comments

Comments
 (0)