| 7 | apply plugin: "io.sentry.android.gradle" |
| 8 | apply plugin: "io.objectbox" |
| 9 |
| 10 | apply plugin: 'org.telegram.lottie-meta' |
| 11 | apply plugin: 'idea' |
| 12 |
| 13 | idea { |
| 14 | module { |
| 15 | excludeDirs += [ |
| 16 | file('jni/third_party'), |
| 17 | file('jni/ffmpeg'), |
| 18 | file('jni/tlottie'), |
| 19 | file('jni/boringssl'), |
| 20 | file('jni/sqlite') |
| 21 | ] |
| 22 | } |
| 23 | } |
| 24 |
| 25 | def verName = APP_VERSION_NAME |
| 26 | def verCode = 1245 |
| 27 |
| 28 |
| 29 | def officialVer = APP_VERSION_NAME |
| 30 | def officialCode = APP_VERSION_CODE |
| 31 |
| 32 | def serviceAccountCredentialsFile = rootProject.file("service_account_credentials.json") |
| 33 |
| 34 | def beta = verName.contains("preview") |
| 35 |
| 36 | if (serviceAccountCredentialsFile.isFile()) { |
| 37 | setupPlay(beta) |
| 38 | play.serviceAccountCredentials = serviceAccountCredentialsFile |
| 39 | } else if (System.getenv().containsKey("ANDROID_PUBLISHER_CREDENTIALS")) { |
| 40 | setupPlay(beta) |
| 41 | } |
| 42 |
| 43 | void setupPlay(boolean beta) { |
| 44 | apply plugin: "com.github.triplet.play" |
| 45 | play { |
| 46 | track = beta ? "beta" : "production" |
| 47 | defaultToAppBundles = true |
| 48 | } |
| 49 | } |
| 50 |
| 51 | configurations { |
| 52 | compile.exclude module: "support-v4" |
| 53 | } |
| 54 |
| 55 | def keystorePwd = null |
| 56 | def alias = null |
| 57 | def pwd = null |
| 58 | def sentry_token = System.getenv("SENTRY_AUTH_TOKEN") |
| 59 | def nagram_build_args = System.getenv("NAGRAM_BUILD_ARGS") |
| 60 | def sentry_upload = project.rootProject.file("sentry.properties").exists() |
| 61 | def disableCMakeRelWithDebInfo = System.getenv("COMPILE_NATIVE") == null |
| 62 |
| 63 | Properties properties |
| 64 | def base64 = System.getenv("LOCAL_PROPERTIES") |
| 65 | if (base64 != null && !base64.isBlank()) { |
| 66 | properties = new Properties() |
| 67 | properties.load(new ByteArrayInputStream(Base64.decoder.decode(base64))) |
| 68 | } else if (project.rootProject.file("local.properties").exists()) { |
| 69 | properties = new Properties() |
| 70 | properties.load(project.rootProject.file("local.properties").newDataInputStream()) |
| 71 | } |
| 72 |
| 73 | if (properties != null) { |
| 74 | keystorePwd = properties.getProperty("KEYSTORE_PASS") |
| 75 | alias = properties.getProperty("ALIAS_NAME") |
| 76 | pwd = properties.getProperty("ALIAS_PASS") |
| 77 | sentry_token = properties.getProperty("SENTRY_AUTH_TOKEN", sentry_token) |
| 78 | nagram_build_args = properties.getProperty("NAGRAM_BUILD_ARGS", nagram_build_args) |
| 79 | } |
| 80 |
| 81 | keystorePwd = keystorePwd ?: System.getenv("KEYSTORE_PASS") |
| 82 | alias = alias ?: System.getenv("ALIAS_NAME") |
| 83 | pwd = pwd ?: System.getenv("ALIAS_PASS") |
| 84 |
| 85 | def targetTask = "" |
| 86 | if (!gradle.startParameter.taskNames.isEmpty()) { |
| 87 | if (gradle.startParameter.taskNames.size == 1) { |
| 88 | targetTask = gradle.startParameter.taskNames[0].toLowerCase() |
| 89 | } |
| 90 | } |
| 91 |
| 92 | def nativeTarget = System.getenv("NATIVE_TARGET") |
| 93 | if (nativeTarget == null) nativeTarget = "" |
| 94 |
| 95 | android { |
| 96 | compileSdkVersion 35 |
| 97 | buildToolsVersion '35.0.0' |
| 98 | ndkVersion rootProject.ext.ndkVersion // 27.2.12479018 |
| 99 |
| 100 | defaultConfig.applicationId = "xyz.nextalone.nagram" |
| 101 |
| 102 | sourceSets { |
| 103 |
| 104 | main { |
| 105 | assets.srcDirs = ["src/main/assets"] |
| 106 | } |
| 107 |
| 108 | debug { |
| 109 | java { |
| 110 | srcDirs "src/main/java" |
| 111 | } |
| 112 | jniLibs { |
| 113 | srcDir "src/main/libs" |
| 114 | } |
| 115 | } |
| 116 |
| 117 | release { |
| 118 | java { |
| 119 | srcDirs "src/main/java" |
| 120 | } |
| 121 | jniLibs { |
| 122 | srcDir "src/main/libs" |
| 123 | } |
| 124 | } |
| 125 | } |
| 126 |
| 127 | externalNativeBuild { |
| 128 | cmake { |
| 129 | path "jni/CMakeLists.txt" |
| 130 | } |
| 131 | } |
| 132 |
| 133 | lintOptions { |
| 134 | disable 'MissingTranslation' |
| 135 | disable 'ExtraTranslation' |
| 136 | disable 'BlockedPrivateApi' |
| 137 | } |
| 138 |
| 139 | compileOptions { |
| 140 | sourceCompatibility JavaVersion.VERSION_11 |
| 141 | targetCompatibility JavaVersion.VERSION_11 |
| 142 |
| 143 | coreLibraryDesugaringEnabled true |
| 144 | } |
| 145 |
| 146 | splits { |
| 147 |
| 148 | abi { |
| 149 | if (targetTask.contains("fdroid")) { |
| 150 | enable false |
| 151 | universalApk true |
| 152 | } else { |
| 153 | enable true |
| 154 | reset() |
| 155 | universalApk false |
| 156 | if (!nativeTarget.isBlank()) { |
| 157 | include nativeTarget |
| 158 | } else { |
| 159 | include 'armeabi-v7a', 'arm64-v8a' |
| 160 | } |
| 161 | } |
| 162 | } |
| 163 |
| 164 | } |
| 165 |
| 166 | defaultConfig { |
| 167 | minSdkVersion 21 |
| 168 | //noinspection ExpiredTargetSdkVersion,OldTargetApi |
| 169 | targetSdkVersion 35 |
| 170 |
| 171 | versionName verName |
| 172 | versionCode verCode |
| 173 |
| 174 | def appId = "11535358" |
| 175 | def appHash = "33d372962fadb01df47e6ceed4e33cd6" |
| 176 |
| 177 | //obtain your own keys at https://core.telegram.org/api/obtaining_api_id |
| 178 |
| 179 | if (properties != null) { |
| 180 | appId = properties.getProperty("TELEGRAM_APP_ID") ?: System.getenv("TELEGRAM_APP_ID") ?: appId |
| 181 | appHash = properties.getProperty("TELEGRAM_APP_HASH") ?: System.getenv("TELEGRAM_APP_HASH") ?: appHash |
| 182 | } |
| 183 |
| 184 | buildConfigField "String", "BUILD_VERSION_STRING", "\"" + verName + "\"" |
| 185 | buildConfigField "long", "BUILD_TIMESTAMP", APP_BUILD_TIMESTAMP + "" |
| 186 | buildConfigField "String", "OFFICIAL_VERSION", "\"" + officialVer + "\"" |
| 187 | buildConfigField "int", "OFFICIAL_VERSION_CODE", officialCode + "" |
| 188 | buildConfigField "int", "APP_ID", appId |
| 189 | buildConfigField "String", "APP_HASH", "\"" + appHash + "\"" |
| 190 |
| 191 | externalNativeBuild { |
| 192 | cmake { |
| 193 | arguments '-DANDROID_STL=c++_static', '-DANDROID_PLATFORM=android-21' //, '-DANDROID_SUPPORT_FLEXIBLE_PAGE_SIZES=ON' |
| 194 | } |
| 195 | } |
| 196 | } |
| 197 |
| 198 | bundle { |
| 199 | language { |
| 200 | enableSplit = false |
| 201 | } |
| 202 | } |
| 203 |
| 204 | kotlinOptions { |
| 205 | jvmTarget = JavaVersion.VERSION_11.toString() |
| 206 | } |
| 207 |
| 208 | testOptions { |
| 209 | unitTests.includeAndroidResources = true |
| 210 | } |
| 211 |
| 212 | signingConfigs { |
| 213 | release { |
| 214 | storeFile project.file("release.keystore") |
| 215 | storePassword keystorePwd |
| 216 | keyAlias alias |
| 217 | keyPassword pwd |
| 218 | } |
| 219 | } |
| 220 |
| 221 | buildTypes { |
| 222 | debug { |
| 223 | isDefault true |
| 224 | debuggable true |
| 225 | jniDebuggable true |
| 226 | multiDexEnabled true |
| 227 | zipAlignEnabled true |
| 228 | signingConfig signingConfigs.release |
| 229 | } |
| 230 |
| 231 | release { |
| 232 | debuggable false |
| 233 | jniDebuggable false |
| 234 | minifyEnabled true |
| 235 | shrinkResources true |
| 236 | multiDexEnabled true |
| 237 | zipAlignEnabled true |
| 238 | proguardFiles getDefaultProguardFile("proguard-android-optimize.txt"), "proguard-rules.pro" |
| 239 | matchingFallbacks = ["release", "debug"] |
| 240 | signingConfig signingConfigs.release |
| 241 | } |
| 242 | } |
| 243 |
| 244 | flavorDimensions "version" |
| 245 |
| 246 | packagingOptions { |
| 247 | jniLibs { |
| 248 | excludes += ['/fabric/**', '/META-INF/native-image/**'] |
| 249 | useLegacyPackaging true |
| 250 | } |
| 251 | resources { |
| 252 | excludes += ['/fabric/**', '/META-INF/*.version', '/META-INF/*.kotlin_module', '/META-INF/native-image/**', '/builddef.lst', '/*.txt', '/DebugProbesKt.bin', '/okhttp3/internal/publicsuffix/NOTICE'] |
| 253 | excludes += ["META-INF/INDEX.LIST"] // hutool |
| 254 | } |
| 255 |
| 256 | def lib = "libtmessages.*.so" |
| 257 | pickFirst "lib/armeabi-v7a/$lib" |
| 258 | pickFirst "lib/arm64-v8a/$lib" |
| 259 | } |
| 260 |
| 261 | buildFeatures { |
| 262 | buildConfig true |
| 263 | } |
| 264 |
| 265 | tasks.configureEach { task -> |
| 266 | if (((task.name.endsWith("Ndk") || task.name.startsWith("generateJsonModel") || task.name.startsWith("externalNativeBuild"))) && !task.name.contains("Debug")) { |
| 267 | task.enabled = false |
| 268 | } |
| 269 | if (task.name.contains("uploadCrashlyticsMappingFile")) { |
| 270 | enabled = false |
| 271 | } |
| 272 | if (disableCMakeRelWithDebInfo && task.name.contains("CMakeRelWithDebInfo")) { |
| 273 | enabled = false |
| 274 | } |
| 275 | } |
| 276 |
| 277 | tasks.configureEach { task -> |
| 278 | if (task.name.startsWith("uploadCrashlyticsMappingFile")) { |
| 279 | task.enabled = false |
| 280 | } else if (task.name.contains("Crashlytics") && task.name.contains("NoGcm")) { |
| 281 | task.enabled = false |
| 282 | } else if (task.name.endsWith("GoogleServices") && task.name.contains("NoGcm")) { |
| 283 | task.enabled = false |
| 284 | } else if (task.name.contains("buildCMakeDebug") && nagram_build_args != null && nagram_build_args.contains("skip_buildCMakeDebug")) { |
| 285 | task.enabled = false |
| 286 | } |
| 287 | } |
| 288 |
| 289 | applicationVariants.configureEach { variant -> |
| 290 | variant.outputs.configureEach { output -> |
| 291 | String gramName = "Nagram" |
| 292 | String first = String.format("%s-v%s(%s)", gramName, versionName, versionCode) |
| 293 | String name = outputFileName.replace("TMessagesProj", first) |
| 294 | name = name.replace("-release", "") |
| 295 | outputFileName = name |
| 296 | } |
| 297 | } |
| 298 |
| 299 | namespace "org.telegram.messenger" |
| 300 | } |
| 301 |
| 302 | def fcmVersion = "23.4.1" |
| 303 | def crashlyticsVersion = "18.6.2" |
| 304 |
| 305 | dependencies { |
| 306 | implementation 'androidx.fragment:fragment:1.8.9' |
| 307 | implementation "androidx.core:core-ktx:1.16.0" |
| 308 | implementation "androidx.palette:palette-ktx:1.0.0" |
| 309 | implementation "androidx.exifinterface:exifinterface:1.3.7" |
| 310 | implementation "androidx.dynamicanimation:dynamicanimation:1.0.0" |
| 311 | implementation "androidx.sharetarget:sharetarget:1.2.0" |
| 312 | implementation "androidx.interpolator:interpolator:1.0.0" |
| 313 | implementation 'androidx.biometric:biometric:1.1.0' |
| 314 |
| 315 | implementation ('com.google.android.gms:play-services-cast-framework:21.4.0') { |
| 316 | exclude group: 'androidx.recyclerview', module: "recyclerview" |
| 317 | } |
| 318 | implementation ("androidx.mediarouter:mediarouter:1.7.0") { |
| 319 | exclude group: 'androidx.recyclerview', module: "recyclerview" |
| 320 | } |
| 321 | implementation 'com.google.zxing:core:3.5.4' |
| 322 |
| 323 | implementation 'androidx.car.app:app:1.7.0' |
| 324 | implementation 'androidx.car.app:app-projected:1.7.0' |
| 325 | implementation 'org.nanohttpd:nanohttpd:2.3.1' |
| 326 |
| 327 | compileOnly 'org.checkerframework:checker-qual:2.5.2' |
| 328 | compileOnly 'org.checkerframework:checker-compat-qual:2.5.0' |
| 329 | implementation "com.google.firebase:firebase-messaging:$fcmVersion" |
| 330 | implementation "com.google.firebase:firebase-crashlytics:$crashlyticsVersion" |
| 331 | implementation 'com.google.android.gms:play-services-maps:18.1.0' |
| 332 | implementation 'com.google.android.gms:play-services-auth:20.4.0' |
| 333 | implementation 'com.google.android.gms:play-services-vision:20.1.3' |
| 334 | implementation 'com.google.android.gms:play-services-wearable:18.0.0' |
| 335 | implementation 'com.google.android.gms:play-services-location:21.0.1' |
| 336 | implementation 'com.google.android.gms:play-services-wallet:19.1.0' |
| 337 | implementation "com.googlecode.mp4parser:isoparser:1.0.6" |
| 338 | implementation 'com.stripe:stripe-android:2.0.2' |
| 339 | // add for auto translate |
| 340 | implementation 'com.google.mlkit:language-id:17.0.6' |
| 341 | implementation 'com.android.billingclient:billing:7.1.1' |
| 342 | implementation 'com.google.code.gson:gson:2.11.0' |
| 343 | implementation 'com.google.guava:guava:31.1-android' |
| 344 | implementation 'com.google.android.play:integrity:1.3.0' |
| 345 | implementation 'com.google.android.gms:play-services-safetynet:18.0.1' |
| 346 |
| 347 | implementation 'com.google.android.gms:play-services-mlkit-subject-segmentation:16.0.0-beta1' |
| 348 | implementation 'com.google.android.gms:play-services-mlkit-image-labeling:16.0.8' |
| 349 |
| 350 | implementation "androidx.credentials:credentials:1.6.0-alpha04" |
| 351 | implementation "androidx.credentials:credentials-play-services-auth:1.6.0-alpha04" |
| 352 |
| 353 | implementation "io.noties.markwon:core:4.6.2" |
| 354 | implementation "io.noties.markwon:ext-strikethrough:4.6.2" |
| 355 | implementation "io.noties.markwon:ext-tables:4.6.2" |
| 356 | implementation "io.noties.markwon:html:4.6.2" |
| 357 | implementation "io.noties.markwon:inline-parser:4.6.2" |
| 358 | implementation("io.noties.markwon:ext-latex:4.6.2") { |
| 359 | exclude group: 'ru.noties', module: 'jlatexmath-android' |
| 360 | } |
| 361 | api project(':jlatexmath') |
| 362 |
| 363 | // implementation 'com.google.mlkit:translate:17.0.3' |
| 364 |
| 365 | // constraints { |
| 366 | // implementation("org.jetbrains.kotlin:kotlin-stdlib-jdk7:1.8.0") { |
| 367 | // because("kotlin-stdlib-jdk7 is now a part of kotlin-stdlib") |
| 368 | // } |
| 369 | implementation("org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.8.0") { |
| 370 | because("kotlin-stdlib-jdk8 is now a part of kotlin-stdlib") |
| 371 | } |
| 372 | // } |
| 373 | implementation ('com.google.android.recaptcha:recaptcha:18.7.1') { |
| 374 | exclude group: "com.google.crypto.tink", module: "tink-android" |
| 375 | } |
| 376 |
| 377 | testImplementation "junit:junit:4.13.2" |
| 378 | testImplementation "androidx.test:core:1.5.0" |
| 379 | testImplementation "org.robolectric:robolectric:4.16.1" |
| 380 |
| 381 | coreLibraryDesugaring 'com.android.tools:desugar_jdk_libs:2.1.5' |
| 382 | } |
| 383 | dependencies { |
| 384 | implementation "androidx.browser:browser:1.8.0" |
| 385 | implementation "androidx.viewpager:viewpager:1.0.0" |
| 386 | implementation "org.jetbrains.kotlinx:kotlinx-coroutines-android:1.9.0" |
| 387 | // map |
| 388 | implementation "org.maplibre.gl:android-sdk:11.13.5" |
| 389 |
| 390 | // ktor |
| 391 | implementation "io.ktor:ktor-client-core:3.3.0" |
| 392 | implementation "io.ktor:ktor-client-okhttp:3.3.0" |
| 393 | implementation "io.ktor:ktor-client-content-negotiation:3.3.0" |
| 394 | implementation "io.ktor:ktor-serialization-kotlinx-json-jvm:3.3.0" |
| 395 | implementation "io.ktor:ktor-client-logging:3.3.0" |
| 396 |
| 397 | implementation "cn.hutool:hutool-core:5.8.42" |
| 398 | implementation "cn.hutool:hutool-crypto:5.8.42" |
| 399 | implementation 'cn.hutool:hutool-http:5.8.42' |
| 400 | // openpgp |
| 401 | implementation project(":openpgp-api") |
| 402 |
| 403 | compileOnly fileTree("libs") |
| 404 |
| 405 | // add for undo and redo |
| 406 | implementation 'org.lsposed.hiddenapibypass:hiddenapibypass:6.1' |
| 407 | // add splash screen |
| 408 | implementation("androidx.core:core-splashscreen:1.2.0") |
| 409 | // add for emoji |
| 410 | implementation 'com.jaredrummler:truetypeparser-light:1.0.0' |
| 411 | // add for up |
| 412 | implementation 'org.unifiedpush.android:connector:3.1.2' |
| 413 | // add for copy webm and tgs to gif |
| 414 | implementation "com.airbnb.android:lottie:6.4.1" |
| 415 | } |
| 416 |
| 417 | apply plugin: "com.google.gms.google-services" |
| 418 | apply plugin: "com.google.firebase.crashlytics" |
| 419 |
| 420 | sentry { |
| 421 | // Disables or enables debug log output, e.g. for for sentry-cli. |
| 422 | // Default is disabled. |
| 423 | debug = false |
| 424 |
| 425 | // The slug of the Sentry organization to use for uploading proguard mappings/source contexts. |
| 426 | org = "pagermaid" |
| 427 |
| 428 | // The slug of the Sentry project to use for uploading proguard mappings/source contexts. |
| 429 | projectName = "nagram" |
| 430 |
| 431 | // The authentication token to use for uploading proguard mappings/source contexts. |
| 432 | // WARNING: Do not expose this token in your build.gradle files, but rather set an environment |
| 433 | // variable and read it into this property. |
| 434 | authToken = sentry_token |
| 435 |
| 436 | // The url of your Sentry instance. If you're using SAAS (not self hosting) you do not have to |
| 437 | // set this. If you are self hosting you can set your URL here |
| 438 | url = null |
| 439 |
| 440 | // Disables or enables the handling of Proguard mapping for Sentry. |
| 441 | // If enabled the plugin will generate a UUID and will take care of |
| 442 | // uploading the mapping to Sentry. If disabled, all the logic |
| 443 | // related to proguard mapping will be excluded. |
| 444 | // Default is enabled. |
| 445 | includeProguardMapping = sentry_upload |
| 446 |
| 447 | // Whether the plugin should attempt to auto-upload the mapping file to Sentry or not. |
| 448 | // If disabled the plugin will run a dry-run and just generate a UUID. |
| 449 | // The mapping file has to be uploaded manually via sentry-cli in this case. |
| 450 | // Default is enabled. |
| 451 | autoUploadProguardMapping = sentry_upload |
| 452 |
| 453 | // Experimental flag to turn on support for GuardSquare's tools integration (Dexguard and External Proguard). |
| 454 | // If enabled, the plugin will try to consume and upload the mapping file produced by Dexguard and External Proguard. |
| 455 | // Default is disabled. |
| 456 | dexguardEnabled = false |
| 457 |
| 458 | // Disables or enables the automatic configuration of Native Symbols |
| 459 | // for Sentry. This executes sentry-cli automatically so |
| 460 | // you don't need to do it manually. |
| 461 | // Default is disabled. |
| 462 | uploadNativeSymbols = sentry_upload |
| 463 |
| 464 | // Whether the plugin should attempt to auto-upload the native debug symbols to Sentry or not. |
| 465 | // If disabled the plugin will run a dry-run. |
| 466 | // Default is enabled. |
| 467 | autoUploadNativeSymbols = sentry_upload |
| 468 |
| 469 | // Does or doesn't include the source code of native code for Sentry. |
| 470 | // This executes sentry-cli with the --include-sources param. automatically so |
| 471 | // you don't need to do it manually. |
| 472 | // This option has an effect only when [uploadNativeSymbols] is enabled. |
| 473 | // Default is disabled. |
| 474 | includeNativeSources = false |
| 475 |
| 476 | // Generates a JVM (Java, Kotlin, etc.) source bundle and uploads your source code to Sentry. |
| 477 | // This enables source context, allowing you to see your source |
| 478 | // code as part of your stack traces in Sentry. |
| 479 | includeSourceContext = sentry_upload |
| 480 |
| 481 | // Configure additional directories to be included in the source bundle which is used for |
| 482 | // source context. The directories should be specified relative to the Gradle module/project's |
| 483 | // root. For example, if you have a custom source set alongside 'main', the parameter would be |
| 484 | // 'src/custom/java'. |
| 485 | additionalSourceDirsForSourceContext = [] |
| 486 |
| 487 | // Enable or disable the tracing instrumentation. |
| 488 | // Does auto instrumentation for specified features through bytecode manipulation. |
| 489 | // Default is enabled. |
| 490 | tracingInstrumentation { |
| 491 | enabled = true |
| 492 |
| 493 | // Specifies a set of instrumentation features that are eligible for bytecode manipulation. |
| 494 | // Defaults to all available values of InstrumentationFeature enum class. |
| 495 | features = [InstrumentationFeature.DATABASE, InstrumentationFeature.FILE_IO, InstrumentationFeature.OKHTTP, InstrumentationFeature.COMPOSE] |
| 496 |
| 497 | // Enable or disable logcat instrumentation through bytecode manipulation. |
| 498 | // Default is enabled. |
| 499 | logcat { |
| 500 | enabled = true |
| 501 |
| 502 | // Specifies a minimum log level for the logcat breadcrumb logging. |
| 503 | // Defaults to LogcatLevel.WARNING. |
| 504 | minLevel = LogcatLevel.WARNING |
| 505 | } |
| 506 |
| 507 | // The set of glob patterns to exclude from instrumentation. Classes matching any of these |
| 508 | // patterns in the project's sources and dependencies JARs won't be instrumented by the Sentry |
| 509 | // Gradle plugin. |
| 510 | // |
| 511 | // Don't include the file extension. Filtering is done on compiled classes and |
| 512 | // the .class suffix isn't included in the pattern matching. |
| 513 | // |
| 514 | // Example usage: |
| 515 | // ``` |
| 516 | // excludes = ['com/example/donotinstrument/**', '**/*Test'] |
| 517 | // ``` |
| 518 | // |
| 519 | // Only supported when using Android Gradle plugin (AGP) version 7.4.0 and above. |
| 520 | excludes = [] |
| 521 | } |
| 522 |
| 523 | // Enable auto-installation of Sentry components (sentry-android SDK and okhttp, timber and fragment integrations). |
| 524 | // Default is enabled. |
| 525 | // Only available v3.1.0 and above. |
| 526 | autoInstallation { |
| 527 | enabled = true |
| 528 |
| 529 | // Specifies a version of the sentry-android SDK and fragment, timber and okhttp integrations. |
| 530 | // |
| 531 | // This is also useful, when you have the sentry-android SDK already included into a transitive dependency/module and want to |
| 532 | // align integration versions with it (if it's a direct dependency, the version will be inferred). |
| 533 | // |
| 534 | // NOTE: if you have a higher version of the sentry-android SDK or integrations on the classpath, this setting will have no effect |
| 535 | // as Gradle will resolve it to the latest version. |
| 536 | // |
| 537 | // Defaults to the latest published Sentry version. |
| 538 | sentryVersion = '8.53.0' |
| 539 | } |
| 540 |
| 541 | // Disables or enables dependencies metadata reporting for Sentry. |
| 542 | // If enabled, the plugin will collect external dependencies and |
| 543 | // upload them to Sentry as part of events. If disabled, all the logic |
| 544 | // related to the dependencies metadata report will be excluded. |
| 545 | // |
| 546 | // Default is enabled. |
| 547 | includeDependenciesReport = true |
| 548 |
| 549 | // Whether the plugin should send telemetry data to Sentry. |
| 550 | // If disabled the plugin won't send telemetry data. |
| 551 | // This is auto disabled if running against a self hosted instance of Sentry. |
| 552 | // Default is enabled. |
| 553 | telemetry = true |
| 554 | } |
| 555 |