Skip to content

Commit c356167

Browse files
authored
Adopt AGP 9 defaults + enable Gradle configuration cache (#62)
- Remove android.enableJetifier=true. 'gradlew checkJetifier' confirms no module uses legacy android.support.* libraries, so Jetifier transforms nothing. The flag is removed in AGP 10; omitting it adopts the default (false). - Remove android.nonFinalResIds=false to adopt the AGP 9 default (true). No Java 'switch (R.id.x)'/'case R.id.x:' usage exists (all switches are on protocol/type/authType ints), so non-final R ids are safe. Flag removed in AGP 10. - Enable org.gradle.configuration-cache=true. Verified: a clean app:assembleOssDebug stores the entry, and a re-run reuses it (47s -> 1s) with renameApksForOssDebug still producing the NekoBox-*-<abi>.apk files. Both deprecation warnings that AGP 9 emitted are now gone.
1 parent b23314d commit c356167

1 file changed

Lines changed: 9 additions & 3 deletions

File tree

gradle.properties

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -15,11 +15,17 @@ org.gradle.jvmargs=-Xmx4g -XX:+UseParallelGC -Dfile.encoding=UTF-8
1515
# Android operating system, and which are packaged with your app's APK
1616
# https://developer.android.com/topic/libraries/support-library/androidx-rn
1717
android.useAndroidX=true
18-
# Automatically convert third-party libraries to use AndroidX
19-
android.enableJetifier=true
18+
# Jetifier (legacy android.support.* -> androidx rewriting) is intentionally NOT enabled.
19+
# `./gradlew checkJetifier` confirms no module uses legacy support libraries, and the
20+
# android.enableJetifier flag is removed in AGP 10. Omitting it adopts the AGP 9 default (false).
2021
# Kotlin code style for this project: "official" or "obsolete":
2122
kotlin.code.style=official
2223
# Gradle parallel build
2324
org.gradle.parallel=true
25+
# Gradle configuration cache: caches the result of the configuration phase so subsequent
26+
# builds skip straight to task execution. Stable since Gradle 8.1.
27+
org.gradle.configuration-cache=true
2428
android.nonTransitiveRClass=false
25-
android.nonFinalResIds=false
29+
# android.nonFinalResIds is left at the AGP 9 default (true). The project has no Java
30+
# `switch (R.id.x)` / `case R.id.x:` usage that would require final (constant) R fields,
31+
# so non-final R ids are safe. The flag is removed in AGP 10.

0 commit comments

Comments
 (0)