Update to Kotlin 1.5 (and associated deps) (#1339)

This commit is contained in:
Zac Sweers
2021-05-07 12:51:33 -04:00
committed by GitHub
parent 45c8595bfa
commit e343751593
12 changed files with 156 additions and 135 deletions

View File

@@ -22,7 +22,7 @@ plugins {
kotlin("jvm")
kotlin("kapt")
id("com.vanniktech.maven.publish")
id("com.github.johnrengelman.shadow") version "6.0.0"
id("com.github.johnrengelman.shadow") version "7.0.0"
}
tasks.withType<KotlinCompile>().configureEach {
@@ -102,6 +102,6 @@ val shadowJar = tasks.shadowJar.apply {
}
artifacts {
runtime(shadowJar)
runtimeOnly(shadowJar)
archives(shadowJar)
}

View File

@@ -31,6 +31,7 @@ import com.squareup.kotlinpoet.asClassName
import com.squareup.kotlinpoet.asTypeName
import com.squareup.moshi.JsonAdapter
import com.squareup.moshi.Types
import java.util.Locale
/** A JsonAdapter that can be used to encode and decode a particular field. */
internal data class DelegateKey(
@@ -50,7 +51,7 @@ internal data class DelegateKey(
"At${it.typeName.rawType().simpleName}"
}
val adapterName = nameAllocator.newName(
"${type.toVariableName().decapitalize()}${qualifierNames}Adapter",
"${type.toVariableName().replaceFirstChar { it.lowercase(Locale.US) }}${qualifierNames}Adapter",
this
)