File tree Expand file tree Collapse file tree 5 files changed +15
-7
lines changed
src/main/java/org/wordpress/android/processor Expand file tree Collapse file tree 5 files changed +15
-7
lines changed Original file line number Diff line number Diff line change @@ -12,6 +12,7 @@ plugins {
1212ext {
1313 wordPressUtilsVersion = ' 2.7.0'
1414 wordPressLoginVersion = ' 0.19.0'
15+ aztecVersion = ' v1.6.0'
1516 gutenbergMobileVersion = ' v1.82.1'
1617 storiesVersion = ' 1.4.0'
1718 aboutAutomatticVersion = ' 0.0.6'
4445
4546 composeVersion = ' 1.1.1'
4647
48+ // annotations/processors
49+ kotlinPoetVersion = ' 1.6.0'
50+ autoServiceVersion = ' 1.0'
51+
4752 // testing
4853 jUnitVersion = ' 4.13'
4954 jUnitExtVersion = ' 1.1.3'
Original file line number Diff line number Diff line change @@ -4,8 +4,6 @@ plugins {
44 id " org.jetbrains.kotlin.plugin.parcelize"
55}
66
7- ext. aztecVersion = ' v1.6.0'
8-
97repositories {
108 maven {
119 url " https://a8c-libs.s3.amazonaws.com/android"
Original file line number Diff line number Diff line change @@ -3,8 +3,11 @@ plugins {
33 id " org.jetbrains.kotlin.kapt"
44}
55
6- ext. kotlinPoetVersion = ' 1.6.0'
7- ext. autoServiceVersion = ' 1.0'
6+ compileKotlin {
7+ kotlinOptions {
8+ allWarningsAsErrors = true
9+ }
10+ }
811
912dependencies {
1013 implementation project(' :libs:annotations' )
Original file line number Diff line number Diff line change @@ -11,6 +11,7 @@ import com.squareup.kotlinpoet.TypeSpec
1111import java.util.Locale
1212
1313class RemoteConfigCheckBuilder (private val remoteFeatures : List <TypeName >) {
14+ @Suppress(" DEPRECATION" )
1415 fun getContent (): FileSpec {
1516 val remoteFeaturesWithNames = remoteFeatures.map {
1617 it.toString()
@@ -49,10 +50,10 @@ class RemoteConfigCheckBuilder(private val remoteFeatures: List<TypeName>) {
4950 private fun buildCheckFunction (remoteFeatures : List <Pair <String , TypeName >>): CodeBlock {
5051 val stringBuilder = StringBuilder ()
5152 remoteFeatures.forEach { feature ->
52- stringBuilder.appendln (" if (${feature.first} .remoteField == null) {" )
53+ stringBuilder.appendLine (" if (${feature.first} .remoteField == null) {" )
5354 val error = " throw IllegalArgumentException(\"\"\" ${feature.second} needs to define remoteField\"\"\" )"
54- stringBuilder.appendln (error)
55- stringBuilder.appendln (" }" )
55+ stringBuilder.appendLine (error)
56+ stringBuilder.appendLine (" }" )
5657 }
5758 return CodeBlock .of(stringBuilder.toString().trimIndent())
5859 }
Original file line number Diff line number Diff line change @@ -24,6 +24,7 @@ import javax.tools.Diagnostic.Kind
2424 " org.wordpress.android.annotation.FeatureInDevelopment"
2525)
2626class RemoteConfigProcessor : AbstractProcessor () {
27+ @Suppress(" DEPRECATION" )
2728 override fun process (p0 : MutableSet <out TypeElement >? , roundEnvironment : RoundEnvironment ? ): Boolean {
2829 val experiments = roundEnvironment?.getElementsAnnotatedWith(Experiment ::class .java)?.map { element ->
2930 val annotation = element.getAnnotation(Experiment ::class .java)
You can’t perform that action at this time.
0 commit comments