mirror of
https://github.com/kalarina-bit/Sparkledns.git
synced 2026-11-22 07:36:09 +00:00
Update dependencies, add a version catalog, backup rules and locale config
- Compose BOM 2026.09.00, Activity 1.13.0, Lifecycle 2.11.0, coroutines 1.11.0, OkHttp 5.4.0, Kotlin 2.4.20; compileSdk 37 for the new AndroidX. - Versions move to gradle/libs.versions.toml. - The VPN service runs as a systemExempted foreground service, the type Android provides for active VPN apps, instead of specialUse. - dataExtractionRules keep everything out of backups and device transfer; localeConfig lets the language be picked in Android settings. - .gitignore keeps signing keys (*.jks, *.keystore) out of the repository.
This commit is contained in:
+13
-12
@@ -1,11 +1,12 @@
|
||||
plugins {
|
||||
id("com.android.application")
|
||||
id("org.jetbrains.kotlin.plugin.compose")
|
||||
alias(libs.plugins.android.application)
|
||||
alias(libs.plugins.kotlin.compose)
|
||||
}
|
||||
|
||||
android {
|
||||
namespace = "cc.skysparkle.sparkledns"
|
||||
compileSdk = 36
|
||||
// The current AndroidX libraries require it
|
||||
compileSdk = 37
|
||||
|
||||
defaultConfig {
|
||||
applicationId = "cc.skysparkle.sparkledns"
|
||||
@@ -71,17 +72,17 @@ android {
|
||||
}
|
||||
|
||||
dependencies {
|
||||
implementation(platform("androidx.compose:compose-bom:2025.09.00"))
|
||||
implementation("androidx.activity:activity-compose:1.10.1")
|
||||
implementation("androidx.compose.ui:ui")
|
||||
implementation("androidx.compose.material3:material3")
|
||||
implementation(platform(libs.androidx.compose.bom))
|
||||
implementation(libs.androidx.activity.compose)
|
||||
implementation(libs.androidx.compose.ui)
|
||||
implementation(libs.androidx.compose.material3)
|
||||
// Already pulled in by Compose at this version; declared because the app uses it directly
|
||||
implementation("androidx.lifecycle:lifecycle-runtime-compose:2.9.0")
|
||||
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-android:1.10.2")
|
||||
implementation("com.squareup.okhttp3:okhttp:4.12.0")
|
||||
implementation(libs.androidx.lifecycle.runtime.compose)
|
||||
implementation(libs.kotlinx.coroutines.android)
|
||||
implementation(libs.okhttp)
|
||||
|
||||
// Debug builds only, never part of a release
|
||||
debugImplementation("com.squareup.leakcanary:leakcanary-android:2.14")
|
||||
debugImplementation(libs.leakcanary.android)
|
||||
|
||||
testImplementation("junit:junit:4.13.2")
|
||||
testImplementation(libs.junit)
|
||||
}
|
||||
@@ -6,7 +6,7 @@
|
||||
<uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" />
|
||||
<uses-permission android:name="android.permission.POST_NOTIFICATIONS" />
|
||||
<uses-permission android:name="android.permission.FOREGROUND_SERVICE" />
|
||||
<uses-permission android:name="android.permission.FOREGROUND_SERVICE_SPECIAL_USE" />
|
||||
<uses-permission android:name="android.permission.FOREGROUND_SERVICE_SYSTEM_EXEMPTED" />
|
||||
<!-- Keeps the scheduled blocklist update after a reboot -->
|
||||
<uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED" />
|
||||
|
||||
@@ -21,6 +21,8 @@
|
||||
<application
|
||||
android:name=".SparkleApp"
|
||||
android:allowBackup="false"
|
||||
android:dataExtractionRules="@xml/data_extraction_rules"
|
||||
android:localeConfig="@xml/locales_config"
|
||||
android:icon="@mipmap/ic_launcher"
|
||||
android:roundIcon="@mipmap/ic_launcher_round"
|
||||
android:label="@string/app_name"
|
||||
@@ -40,7 +42,7 @@
|
||||
<service
|
||||
android:name=".DohVpnService"
|
||||
android:exported="false"
|
||||
android:foregroundServiceType="specialUse"
|
||||
android:foregroundServiceType="systemExempted"
|
||||
android:permission="android.permission.BIND_VPN_SERVICE">
|
||||
<intent-filter>
|
||||
<action android:name="android.net.VpnService" />
|
||||
@@ -48,9 +50,6 @@
|
||||
<meta-data
|
||||
android:name="android.net.VpnService.SUPPORTS_ALWAYS_ON"
|
||||
android:value="true" />
|
||||
<property
|
||||
android:name="android.app.PROPERTY_SPECIAL_USE_FGS_SUBTYPE"
|
||||
android:value="Local DNS-over-HTTPS VPN that keeps encrypted DNS active while the user has it enabled" />
|
||||
</service>
|
||||
|
||||
<service
|
||||
|
||||
@@ -0,0 +1,15 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<data-extraction-rules>
|
||||
<cloud-backup>
|
||||
<exclude domain="root" />
|
||||
<exclude domain="database" />
|
||||
<exclude domain="sharedpref" />
|
||||
<exclude domain="file" />
|
||||
</cloud-backup>
|
||||
<device-transfer>
|
||||
<exclude domain="root" />
|
||||
<exclude domain="database" />
|
||||
<exclude domain="sharedpref" />
|
||||
<exclude domain="file" />
|
||||
</device-transfer>
|
||||
</data-extraction-rules>
|
||||
@@ -0,0 +1,9 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<locale-config xmlns:android="http://schemas.android.com/apk/res/android">
|
||||
<locale android:name="en" />
|
||||
<locale android:name="de" />
|
||||
<locale android:name="ja" />
|
||||
<locale android:name="lt" />
|
||||
<locale android:name="ru" />
|
||||
<locale android:name="zh" />
|
||||
</locale-config>
|
||||
Reference in New Issue
Block a user