55@file:Suppress(" UnstableApiUsage" , " SpellCheckingInspection" )
66
77import com.android.build.api.variant.FilterConfiguration.FilterType.ABI
8- import io.sentry.android.gradle.instrumentation.logcat.LogcatLevel
98import java.util.Properties
109
1110plugins {
@@ -14,11 +13,8 @@ plugins {
1413 id(" com.mikepenz.aboutlibraries.plugin" )
1514 kotlin(" android" )
1615 kotlin(" kapt" )
17- id(" com.google.devtools.ksp" ) version " 1.8.22-1.0.11"
18- id(" io.sentry.android.gradle" ) version " 3.12.0"
16+ id(" com.google.devtools.ksp" ) version " 1.9.10-1.0.13"
1917}
20-
21- val hasSentryConfig = File (rootProject.projectDir, " sentry.properties" ).exists()
2218android {
2319 // functions to get git info: gitCommitHash, gitBranch, gitRemote
2420 val gitCommitHash = providers.exec {
@@ -52,8 +48,8 @@ android {
5248 applicationId = " com.fox2code.mmm"
5349 minSdk = 26
5450 targetSdk = 34
55- versionCode = 85
56- versionName = " 2.3.1 "
51+ versionCode = 86
52+ versionName = " 2.3.2 "
5753 vectorDrawables {
5854 useSupportLibrary = true
5955 }
@@ -85,10 +81,6 @@ android {
8581 " en"
8682 )
8783 )
88- // ksp room processor
89- room {
90- schemaLocationDir.set(file(" roomSchemas" ))
91- }
9284 }
9385
9486 splits {
@@ -159,39 +151,23 @@ android {
159151 buildConfigField(" boolean" , " DEFAULT_ENABLE_CRASH_REPORTING" , " true" )
160152 buildConfigField(" boolean" , " DEFAULT_ENABLE_CRASH_REPORTING_PII" , " true" )
161153 buildConfigField(" boolean" , " DEFAULT_ENABLE_ANALYTICS" , " true" )
162- val properties = Properties ()
163- if (project.rootProject.file(" local.properties" ).exists()) {
164- properties.load(project.rootProject.file(" local.properties" ).reader())
165- // grab matomo.url
166- buildConfigField(
167- " String" , " ANALYTICS_ENDPOINT" , " \" " + properties.getProperty(
168- " matomo.url" , " https://s-api.androidacy.com/matomo.php"
169- ) + " \" "
170- )
171- } else {
172- buildConfigField(
173- " String" , " ANALYTICS_ENDPOINT" , " \" https://s-api.androidacy.com/matomo.php\" "
174- )
175- }
176154 buildConfigField(" boolean" , " ENABLE_PROTECTION" , " true" )
177155 // Get the androidacy client ID from the androidacy.properties
178156
179157 val propertiesA = Properties ()
180- // If androidacy.properties doesn"t exist, use the default client ID which is heavily
181- // rate limited to 30 requests per minute
158+ val default = " 5KYccdYxWB2RxMq5FTbkWisXi2dS6yFN9R7RVlFCG98FRdz6Mf5ojY2fyJCUlXJZ"
182159 if (project.rootProject.file(" androidacy.properties" ).exists()) {
183160 propertiesA.load(project.rootProject.file(" androidacy.properties" ).reader())
184- properties .setProperty(
185- " client_id" , " \" " + propertiesA.getProperty(
161+ propertiesA .setProperty(
162+ " client_id" , propertiesA.getProperty(
186163 " client_id" ,
187- " 5KYccdYxWB2RxMq5FTbkWisXi2dS6yFN9R7RVlFCG98FRdz6Mf5ojY2fyJCUlXJZ "
188- ) + " \" "
164+ default
165+ )
189166 )
190167 } else {
191- properties.setProperty(
192- " client_id" , " 5KYccdYxWB2RxMq5FTbkWisXi2dS6yFN9R7RVlFCG98FRdz6Mf5ojY2fyJCUlXJZ"
193- )
168+ propertiesA.setProperty(" client_id" , " \" " + default + " \" " )
194169 }
170+
195171 buildConfigField(
196172 " String" , " ANDROIDACY_CLIENT_ID" , " \" " + propertiesA.getProperty(" client_id" ) + " \" "
197173 )
@@ -228,38 +204,21 @@ android {
228204 buildConfigField(" boolean" , " DEFAULT_ENABLE_CRASH_REPORTING" , " true" )
229205 buildConfigField(" boolean" , " DEFAULT_ENABLE_CRASH_REPORTING_PII" , " true" )
230206 buildConfigField(" boolean" , " DEFAULT_ENABLE_ANALYTICS" , " true" )
231- val properties = Properties ()
232- if (project.rootProject.file(" local.properties" ).exists()) {
233- properties.load(project.rootProject.file(" local.properties" ).reader())
234- // grab matomo.url
235- buildConfigField(
236- " String" , " ANALYTICS_ENDPOINT" , " \" " + properties.getProperty(
237- " matomo.url" , " https://s-api.androidacy.com/matomo.php"
238- ) + " \" "
239- )
240- } else {
241- buildConfigField(
242- " String" , " ANALYTICS_ENDPOINT" , " \" https://s-api.androidacy.com/matomo.php\" "
243- )
244- }
245207 buildConfigField(" boolean" , " ENABLE_PROTECTION" , " true" )
246208 // Get the androidacy client ID from the androidacy.properties
247209
248210 val propertiesA = Properties ()
249- // If androidacy.properties doesn"t exist, use the default client ID which is heavily
250- // rate limited to 30 requests per minute
211+ val default = " 5KYccdYxWB2RxMq5FTbkWisXi2dS6yFN9R7RVlFCG98FRdz6Mf5ojY2fyJCUlXJZ"
251212 if (project.rootProject.file(" androidacy.properties" ).exists()) {
252213 propertiesA.load(project.rootProject.file(" androidacy.properties" ).reader())
253- properties .setProperty(
254- " client_id" , " \" " + propertiesA.getProperty(
255- " play_client_id " ,
256- " 5KYccdYxWB2RxMq5FTbkWisXi2dS6yFN9R7RVlFCG98FRdz6Mf5ojY2fyJCUlXJZ "
257- ) + " \" "
214+ propertiesA .setProperty(
215+ " client_id" , propertiesA.getProperty(
216+ " client_id " ,
217+ default
218+ )
258219 )
259220 } else {
260- properties.setProperty(
261- " client_id" , " 5KYccdYxWB2RxMq5FTbkWisXi2dS6yFN9R7RVlFCG98FRdz6Mf5ojY2fyJCUlXJZ"
262- )
221+ propertiesA.setProperty(" client_id" , " \" " + default + " \" " )
263222 }
264223 buildConfigField(
265224 " String" , " ANDROIDACY_CLIENT_ID" , " \" " + propertiesA.getProperty(" client_id" ) + " \" "
@@ -300,20 +259,6 @@ android {
300259 buildConfigField(" boolean" , " DEFAULT_ENABLE_CRASH_REPORTING" , " false" )
301260 buildConfigField(" boolean" , " DEFAULT_ENABLE_CRASH_REPORTING_PII" , " false" )
302261 buildConfigField(" boolean" , " DEFAULT_ENABLE_ANALYTICS" , " false" )
303- val properties = Properties ()
304- if (project.rootProject.file(" local.properties" ).exists()) {
305- properties.load(project.rootProject.file(" local.properties" ).reader())
306- // grab matomo.url
307- buildConfigField(
308- " String" , " ANALYTICS_ENDPOINT" , " \" " + properties.getProperty(
309- " matomo.url" , " https://s-api.androidacy.com/matomo.php"
310- ) + " \" "
311- )
312- } else {
313- buildConfigField(
314- " String" , " ANALYTICS_ENDPOINT" , " \" https://s-api.androidacy.com/matomo.php\" "
315- )
316- }
317262 buildConfigField(" boolean" , " ENABLE_PROTECTION" , " true" )
318263
319264 // Repo with ads or tracking feature are disabled by default for the
@@ -355,44 +300,6 @@ android {
355300 }
356301}
357302
358- sentry {
359-
360- includeProguardMapping.set(true )
361-
362- autoUploadProguardMapping.set(hasSentryConfig)
363-
364- experimentalGuardsquareSupport.set(true )
365-
366- uploadNativeSymbols.set(hasSentryConfig)
367-
368- includeNativeSources.set(hasSentryConfig)
369-
370- tracingInstrumentation {
371- enabled.set(true )
372-
373- logcat {
374- enabled.set(true )
375-
376- minLevel.set(LogcatLevel .WARNING )
377- }
378- }
379-
380- autoInstallation {
381- enabled.set(true )
382- }
383-
384- includeDependenciesReport.set(true )
385- includeSourceContext.set(hasSentryConfig)
386-
387- // Includes additional source directories into the source bundle.
388- // These directories are resolved relative to the project directory.
389- additionalSourceDirsForSourceContext.set(setOf (" src/main/java" , " src/main/kotlin" ))
390-
391- org.set(" androidacy" )
392- projectName.set(" foxmmm" )
393- uploadNativeSymbols.set(hasSentryConfig)
394- }
395-
396303val abiCodes = mapOf (" armeabi-v7a" to 1 , " x86" to 2 , " x86_64" to 3 , " arm64-v8a" to 4 )
397304
398305// For per-density APKs, create a similar map:
@@ -452,11 +359,7 @@ dependencies {
452359 implementation(" androidx.swiperefreshlayout:swiperefreshlayout:1.1.0" )
453360 implementation(" androidx.webkit:webkit:1.8.0" )
454361 implementation(" com.google.android.material:material:1.9.0" )
455- implementation(" dev.rikka.rikkax.layoutinflater:layoutinflater:1.3.0" )
456- implementation(" dev.rikka.rikkax.insets:insets:1.3.0" )
457- implementation(" com.github.KieronQuinn:MonetCompat:0.4.1" )
458- implementation(" com.github.Fox2Code.FoxCompat:foxcompat:1.2.14" )
459- implementation(" com.github.Fox2Code.FoxCompat:hiddenapis:1.2.14" )
362+
460363 implementation(" com.mikepenz:aboutlibraries:10.8.3" )
461364
462365 // Utils
@@ -481,9 +384,6 @@ dependencies {
481384 implementation(" com.github.Fox2Code:RosettaX:1.0.9" )
482385 implementation(" com.github.Fox2Code:AndroidANSI:1.2.1" )
483386
484- // sentry
485- implementation(" io.sentry:sentry-android:6.29.0" )
486-
487387 // Markdown
488388 // TODO: switch to an updated implementation
489389 implementation(" io.noties.markwon:core:4.6.2" )
@@ -493,10 +393,6 @@ dependencies {
493393 implementation(" com.google.net.cronet:cronet-okhttp:0.1.0" )
494394 implementation(" com.caverock:androidsvg:1.4" )
495395
496- implementation(" dev.rikka.rikkax.core:core:1.4.1" )
497- implementation(" org.lsposed.hiddenapibypass:hiddenapibypass:4.3" )
498- implementation(" com.github.tiann:FreeReflection:3.1.0" )
499-
500396 implementation(" androidx.core:core-ktx:1.12.0" )
501397
502398 // timber
@@ -510,7 +406,7 @@ dependencies {
510406 implementation(" org.apache.commons:commons-compress:1.24.0" )
511407
512408 // analytics
513- implementation(" com.github.matomo-org:matomo- sdk-android:HEAD " )
409+ implementation(" ly.count.android: sdk:23.8.2 " )
514410
515411 // annotations
516412 implementation(" org.jetbrains:annotations-java5:24.0.1" )
0 commit comments