Skip to content

Commit 13bd0a9

Browse files
runningcodeclaude
andcommitted
refactor(distribution): Match enabled convention with sizeAnalysis
Set distribution.enabled convention to match sizeAnalysis.enabled, which uses CI detection (currently evaluates to false). 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
1 parent fc8008a commit 13bd0a9

1 file changed

Lines changed: 7 additions & 2 deletions

File tree

plugin-build/src/main/kotlin/io/sentry/android/gradle/extensions/DistributionExtension.kt

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,25 @@
11
package io.sentry.android.gradle.extensions
22

3+
import io.sentry.android.gradle.util.CiUtils.isCi
34
import javax.inject.Inject
45
import org.gradle.api.model.ObjectFactory
56
import org.gradle.api.provider.Property
7+
import org.gradle.api.provider.ProviderFactory
68
import org.gradle.api.provider.SetProperty
79
import org.jetbrains.annotations.ApiStatus.Experimental
810

911
@Experimental
10-
open class DistributionExtension @Inject constructor(objects: ObjectFactory) {
12+
open class DistributionExtension
13+
@Inject
14+
constructor(objects: ObjectFactory, providerFactory: ProviderFactory) {
1115

1216
/**
1317
* Controls whether build distribution uploads are enabled.
1418
*
1519
* Defaults to false.
1620
*/
17-
val enabled: Property<Boolean> = objects.property(Boolean::class.java).convention(false)
21+
val enabled: Property<Boolean> =
22+
objects.property(Boolean::class.java).convention(providerFactory.isCi() && false)
1823

1924
/**
2025
* Set of Android build variants that should have the auto-update SDK added and auth token

0 commit comments

Comments
 (0)